Index: trunk/phase3/maintenance/tests/phpunit/Makefile |
— | — | @@ -1,20 +1,35 @@ |
2 | | -.PHONY: help test phpunit install |
| 2 | +.PHONY: help test phpunit install coverage |
3 | 3 | |
| 4 | +CONFIG_FILE = suite.xml |
| 5 | +FLAGS = |
| 6 | +PU = phpunit --configuration ${CONFIG_FILE} |
| 7 | + |
4 | 8 | all test: phpunit |
5 | 9 | |
6 | 10 | phpunit: |
7 | | - phpunit --configuration suite.xml |
| 11 | + ${PU} |
8 | 12 | |
9 | 13 | install: |
10 | 14 | pear channel-discover pear.phpunit.de |
11 | 15 | pear install phpunit/PHPUnit |
12 | 16 | |
13 | 17 | tap: |
14 | | - phpunit --configuration suite.xml --tap |
| 18 | + ${PU} --tap |
15 | 19 | |
| 20 | +coverage: |
| 21 | + ${PU} --coverage-html ../../../docs/code-coverage |
| 22 | + |
16 | 23 | help: |
| 24 | + # Usage: |
| 25 | + # make <target> [OPTION=value] |
| 26 | + # |
17 | 27 | # Targets: |
18 | 28 | # phpunit (default) Run all the tests with phpunit |
19 | 29 | # install Install PHPUnit from phpunit.de |
20 | 30 | # tap Run the tests individually through Test::Harness's prove(1) |
21 | 31 | # help You're looking at it! |
| 32 | + # coverage Run the tests and generates an HTML code coverage report |
| 33 | + # You will need the Xdebug PHP extension for the later. |
| 34 | + # Options: |
| 35 | + # CONFIG_FILE Path to a PHPUnit configuration file (default: suite.xml) |
| 36 | + # FLAGS Additional flags to pass to PHPUnit |
Index: trunk/phase3/docs/code-coverage/README |
— | — | @@ -0,0 +1,2 @@ |
| 2 | +This directory is for the auto-generated phpunit code coverage. |
| 3 | +Run 'make coverage' in the maintenance/tests/phpunit subdirectory to build. |
Property changes on: trunk/phase3/docs/code-coverage |
___________________________________________________________________ |
Added: svn:ignore |
1 | 4 | + *.css |
*.gif |
*.html |
*.js |
*.png |