1 .PHONY
: help
test phpunit
install coverage warning destructive parser noparser safe databaseless list-groups
5 CONFIG_FILE
= $(shell pwd
)/suite.xml
7 PU
= ${PHP} phpunit.php
--configuration
${CONFIG_FILE} ${FLAGS}
12 # Use 'make help' to get usage
13 @echo
"WARNING -- some tests are DESTRUCTIVE and will alter your wiki."
14 @echo
"DO NOT RUN THESE TESTS on a production wiki."
16 @echo
"Until the default suites are made non-destructive, you can run"
17 @echo
"the destructive tests like so:"
18 @echo
" make destructive"
20 @echo
"Some tests are expected to be safe, you can run them with"
23 @echo
"You are recommended to run them with read-only credentials, though."
25 @echo
"If you don't have a database running, you can still run"
26 @echo
" make databaseless"
35 php install-phpunit.sh
41 ${PU} --coverage-html ..
/..
/..
/docs
/code-coverage
47 ${PU} --exclude-group Parser
,Broken
50 ${PU} --exclude-group Broken
,Destructive
53 ${PU} --exclude-group Broken
,Destructive
,Database
60 # make <target> [OPTION=value]
63 # phpunit (default) Run all the tests with phpunit
64 # install Install PHPUnit from phpunit.de
65 # tap Run the tests individually through Test::Harness's prove(1)
66 # help You're looking at it!
67 # coverage Run the tests and generates an HTML code coverage report
68 # You will need the Xdebug PHP extension for the later.
69 # [no]parser Skip or only run Parser tests
71 # list-groups List availabe Tests groups.
74 # CONFIG_FILE Path to a PHPUnit configuration file (default: suite.xml)
75 # FLAGS Additional flags to pass to PHPUnit