The purpose of this project is to introduce developers to mocking using PHPUnit.
Here are the steps you need to go through to get the tests running. If you are having trouble then refer to the project Sample PHPUnit Setup
Install the following:
- PHP 5.3 or higher
- Composer
In the root directory of the project run composer. This will pull down all the dependencies:
composer install
You should now be able to run the unit tests. From the root directory of this project run:
./vendor/bin/phpunit
You should see an output like this:
PHPUnit 4.8.0 by Sebastian Bergmann and contributors.
Time: 56 ms, Memory: 2.75MB
OK (1 test, 1 assertion)
The important bit is OK (1 test, 1 assertion)
this means the tests have run successfully.
Type git log -1
to see what the nest steps are.