Installing PHPUnit via PEAR

I had the same problem, try:

pear clear-cache

I had the same problem yesterday, and solved it by updating the channels

pear clear-cache
pear update-channels

before trying to install phpUnit.

Hope this helps.


It simply installs me when I type:

pear channel-discover pear.phpunit.de
pear install --onlyreqdeps phpunit/PHPUnit

Maybe there is a problem with the versions, you may set the preferred_state of the pear packages to different than stable:

pear config-set preferred_state beta

Please follow these steps:

    1. pear config-set auto_discover 1
    2. pear install pear.phpunit.de/PHPUnit -> here I got: installation failed.
    3. Try: pear clear-cache -> executed successfully
    4. pear update-channels -> executed successfully
    5. pear install pear.phpunit.de/PHPUnit -> successfully executed.