Skip to content

Commit

Permalink
Merge pull request #210 from paulholden/pcov-coverage
Browse files Browse the repository at this point in the history
Update code coverage documentation to use pcov.
  • Loading branch information
stronk7 committed May 5, 2022
2 parents 9979aad + 05ea81d commit 640c8e5
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion README.md
Expand Up @@ -109,7 +109,14 @@ OK (2 tests, 7 assertions)
```

Notes:
* If you want to run test with coverage report, use command: `bin/moodle-docker-compose exec webserver phpdbg -qrr vendor/bin/phpunit --coverage-text auth_manual_testcase auth/manual/tests/manual_test.php`
* If you want to run tests with code coverage reports:
```
# Build component configuration
bin/moodle-docker-compose exec webserver php admin/tool/phpunit/cli/util.php --buildcomponentconfigs
# Execute tests for component
bin/moodle-docker-compose exec webserver php -d pcov.enabled=1 -d pcov.directory=. vendor/bin/phpunit --configuration reportbuilder --coverage-text
```
* See available [Command-Line Options](https://phpunit.readthedocs.io/en/9.5/textui.html#textui-clioptions) for further info

## Use containers for manual testing

Expand Down

0 comments on commit 640c8e5

Please sign in to comment.