PHPUnit Installation using PEAR
Installing PHPUnit
pear.phpunit.de) that is used to distribute PHPUnit needs to be registered with the local PEAR environment. Furthermore, a component that PHPUnit depends upon is hosted on the Symfony Components PEAR channel (pear.symfony-project.com). #> pear channel-discover pear.phpunit.de #> pear channel-discover components.ez.no #> pear channel-discover pear.symfony-project.comThis has to be done only once. Now the PEAR Installer can be used to install packages from the PHPUnit channel:
Check the List of Packages in Remote PHPUnit. #> pear remote-list -c phpunitInstall PHPUnit Using this command#> pear install phpunit/PHPUnit
Check the Installed PHPUnit Packages #> Pear list -c phpunitCheck PHPUnit_Selenium installed in that list.After the installation you can find the PHPUnit source files inside your local PEAR directory; the path is usually
/usr/lib/php/PHPUnit. Or /usr/local/lib/php/PHPUnitIf you are facing installation error while follow the above steps?Then Try this. pear update-channelspear install --onlyreqdeps phpunit/PHPUnit.