X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=doc%2Fmd%2FUnit-tests.md;h=651b546d09f90f2429d09a14d54e14a37264b69e;hb=a8a38401f006fdaeb97896ed1c6429d0ab825eb8;hp=da9931095f96cb08517ab50e461376f91c121a81;hpb=7a7a5237822207171e535fc00de253fbfd25c5a2;p=github%2Fshaarli%2FShaarli.git diff --git a/doc/md/Unit-tests.md b/doc/md/Unit-tests.md index da993109..651b546d 100644 --- a/doc/md/Unit-tests.md +++ b/doc/md/Unit-tests.md @@ -18,9 +18,9 @@ $ composer install $ composer update ``` -#### Install and enable Xdebug to generate PHPUnit coverage reports +#### Install Xdebug -See http://xdebug.org/docs/install +Xdebug must be installed and enable for PHPUnit to generate coverage reports. See http://xdebug.org/docs/install. ```bash # for Debian-based distributions @@ -31,6 +31,7 @@ $ pacman -S xdebug ``` Then add the following line to `/etc/php/php.ini`: + ```ini zend_extension=xdebug.so ``` @@ -39,12 +40,7 @@ zend_extension=xdebug.so Run `make test` and ensure tests return `OK`. If tests return failures, refer to PHPUnit messages and fix your code/tests accordingly. - -#### Test results and coverage - -By default, PHPUnit will run all suitable tests found under the `tests` directory. - -Each test has 3 possible outcomes: +By default, PHPUnit will run all suitable tests found under the `tests` directory. Each test has 3 possible outcomes: - `.` - success - `F` - failure: the test was run but its results are invalid