JDesigns
JDesigns

Reputation: 2332

installing phpunit and examples

I am trying to learn PHPUnit. I use MacOS X and just installed PHPUnit using PEAR by doing this:

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

After installation, it's located in pear/share/pear/PHPUnit. It has Extensions and Framework folders.

I tried creating the examples from the Pear PHPUnit tutorial, but in the example it says it requires PHPUnit.php and I don't see that file. Do I need to install anything else to make this work?

Also, where should the example scripts be placed?

Can anyone please guide me in setting up this PHPunit test and try it with one example? Thanks.

Upvotes: 0

Views: 930

Answers (1)

Gordon
Gordon

Reputation: 316969

The docs located at the pear.phpunit.de channel are completely out of date. Please do not use them anymore. Quoting Sebastian Bergmann, author of PHPUnit:

Whoever is responsible for the PEAR Manual: please remove http://bit.ly/gU8eEG as it confuses people (and search engines).

The official docs are located at:

To install PHPUnit, follow the instructions at the official phpunit website instead:

e.g. do

pear channel-discover pear.phpunit.de
pear channel-discover components.ez.no
pear channel-discover pear.symfony-project.com

and then

pear install --alldeps --force phpunit/PHPUnit

Upvotes: 4

Related Questions