r74969 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r74968‎ | r74969 | r74970 >
Date:21:36, 18 October 2010
Author:hashar
Status:deferred
Tags:
Comment:
Add parser tests to the 'Parser' group
Makefile gets some additional targets
Modified paths:
  • /trunk/phase3/maintenance/tests/phpunit/Makefile (modified) (history)
  • /trunk/phase3/maintenance/tests/phpunit/includes/parser/MediaWikiParserTest.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/tests/phpunit/includes/parser/MediaWikiParserTest.php
@@ -24,7 +24,7 @@
2525 $tester->count = 0;
2626
2727 foreach ( $iter as $test ) {
28 - $tester->suite->addTest( new ParserUnitTest( $tester, $test ) );
 28+ $tester->suite->addTest( new ParserUnitTest( $tester, $test ), array( 'Parser' ) );
2929 $tester->count++;
3030 }
3131
Index: trunk/phase3/maintenance/tests/phpunit/Makefile
@@ -1,4 +1,5 @@
2 -.PHONY: help test phpunit install coverage warning destructive
 2+.PHONY: help test phpunit install coverage warning destructive parser noparser list-groups
 3+.DEFAULT: warning
34
45 SHELL = /bin/sh
56 CONFIG_FILE = $(shell pwd)/suite.xml
@@ -8,6 +9,7 @@
910 all test: warning
1011
1112 warning:
 13+ # Use 'make help' to get usage
1214 @echo "WARNING -- these tests are DESTRUCTIVE and will alter your wiki."
1315 @echo "DO NOT RUN THESE TESTS on a production wiki."
1416 @echo ""
@@ -32,6 +34,15 @@
3335 coverage:
3436 ${PU} --coverage-html ../../../docs/code-coverage
3537
 38+parser:
 39+ ${PU} --group Parser
 40+
 41+noparser:
 42+ ${PU} --exclude-group Parser
 43+
 44+list-groups:
 45+ ${PU} --list-groups
 46+
3647 help:
3748 # Usage:
3849 # make <target> [OPTION=value]
@@ -43,6 +54,10 @@
4455 # help You're looking at it!
4556 # coverage Run the tests and generates an HTML code coverage report
4657 # You will need the Xdebug PHP extension for the later.
 58+ # [no]parser Skip or only run Parser tests
 59+ #
 60+ # list-groups List availabe Tests groups.
 61+ #
4762 # Options:
4863 # CONFIG_FILE Path to a PHPUnit configuration file (default: suite.xml)
4964 # FLAGS Additional flags to pass to PHPUnit

Status & tagging log