FormatJson: Make it possible to change the indent string
[lhc/web/wiklou.git] / tests / phpunit / Makefile
index 26c39f3..c3e2a30 100644 (file)
@@ -2,28 +2,32 @@
 .DEFAULT: warning
 
 SHELL = /bin/sh
-CONFIG_FILE = $(shell pwd)/suite.xml
+CONFIG_FILE = ${PWD}/suite.xml
 PHP = php
 PU = ${PHP} phpunit.php --configuration ${CONFIG_FILE} ${FLAGS}
 
 all test: warning
 
 warning:
-       # Use 'make help' to get usage
+       @echo "Run 'make help' to get usage"
+       @echo ""
        @echo "WARNING -- some tests are DESTRUCTIVE and will alter your wiki."
        @echo "DO NOT RUN THESE TESTS on a production wiki."
        @echo ""
-       @echo "Until the default suites are made non-destructive, you can run"
+       @echo "Until the default tests are made non-destructive, you can run"
        @echo "the destructive tests like so:"
-       @echo "  make destructive"
+       @echo ""
+       @echo "    make destructive"
        @echo ""
        @echo "Some tests are expected to be safe, you can run them with"
-       @echo "  make safe"
        @echo ""
-       @echo "You are recommended to run them with read-only credentials, though."
+       @echo "    make safe"
+       @echo ""
+       @echo "You are recommended to run the tests with read-only credentials."
        @echo ""
        @echo "If you don't have a database running, you can still run"
-       @echo "  make databaseless"
+       @echo ""
+       @echo "    make databaseless"
        @echo ""
 
 destructive: phpunit
@@ -32,25 +36,36 @@ phpunit:
        ${PU}
 
 install:
-       php install-phpunit.sh
+       ./install-phpunit.sh
 
 tap:
        ${PU} --tap
 
 coverage:
-       ${PU} --coverage-html ../../../docs/code-coverage
+       ${PU} --coverage-html ../../docs/code-coverage
 
 parser:
        ${PU} --group Parser
-
+parserfuzz:
+       @echo "******************************************************************"
+       @echo "* This WILL kill your computer by eating all memory AND all swap *"
+       @echo "*                                                                *"
+       @echo "* If you are on a production machine. ABORT NOW!!                *"
+       @echo "*  Press control+C to stop                                       *"
+       @echo "*                                                                *"
+       @echo "******************************************************************"
+       ${PU} --group Parser,ParserFuzz
 noparser:
-       ${PU} --exclude-group Parser,Broken
+       ${PU} --exclude-group Parser,Broken,ParserFuzz,Stub
 
 safe:
-       ${PU} --exclude-group Broken,Destructive
+       ${PU} --exclude-group Broken,ParserFuzz,Destructive,Stub
 
 databaseless:
-       ${PU} --exclude-group Broken,Destructive,Database
+       ${PU} --exclude-group Broken,ParserFuzz,Destructive,Database,Stub
+
+database:
+       ${PU} --exclude-group Broken,ParserFuzz,Destructive,Stub --group Database
 
 list-groups:
        ${PU} --list-groups
@@ -62,7 +77,7 @@ help:
        # Targets:
        #   phpunit (default)   Run all the tests with phpunit
        #   install             Install PHPUnit from phpunit.de
-       #   tap                 Run the tests individually through Test::Harness's prove(1)     
+       #   tap                 Run the tests individually through Test::Harness's prove(1)
        #   help                You're looking at it!
        #   coverage            Run the tests and generates an HTML code coverage report
        #                       You will need the Xdebug PHP extension for the later.