jenkins-bot 0c045de899 Merge "registration: Let extensions add PHP version requirements" 6 éve
..
data 2901b84c49 Merge "TemplateParser: Pass FLAG_MUSTACHELOOKUP to enable parent context access" 6 éve
docs 7c78f7624f Clean up ExportDemoTest 10 éve
documentation 506c2f4d57 RELEASE-NOTES: Use New/Changed/Removed pattern for Configuration section 6 éve
includes 0c045de899 Merge "registration: Let extensions add PHP version requirements" 6 éve
languages dbe89abb9e languages: Add coverage for 'ar' and 'ml' normalize() 6 éve
maintenance da9d5c2188 Schema change for reading ct_tag_id instead of ct_tag 6 éve
mocks 2d5b2f0f6a Avoid constructing Title objects in data providers 6 éve
skins 074baa39f5 Convert HTTP links to MediaWiki.org to HTTPS 6 éve
structure 480b653720 StructureTest::testUnitTestFileNamesEndWithTest() should not shell out 6 éve
suites c472b7ca50 Reset services in ParserTestTopLevelSuite. 6 éve
tests 5322107191 Reset services before every test 6 éve
HamcrestPHPUnitIntegration.php 1a2ef35559 Add HamcrestPHPUnitIntegration trait 6 éve
LessFileCompilationTest.php 3f1e9fa268 resourceloader: Tidy up RL to simplify ResourceLoaderEditToolbarModule 9 éve
Makefile 6117fb244f Refactor parser tests 8 éve
MediaWikiCoversValidator.php dafe195c28 Verify that all @covers tags are sane when running tests 7 éve
MediaWikiLangTestCase.php 90d4f56fe4 Mass conversion of $wgContLang to service 6 éve
MediaWikiPHPUnitCommand.php 65adc37348 Make phpunit.php less hackish, and install the listener unconditionally 6 éve
MediaWikiPHPUnitTestListener.php 7717aa2838 Add hooks to MediaWikiPHPUnitTestListener start/endTest 6 éve
MediaWikiTestCase.php 4da52463e3 Ensure database is setup in MediaWikiTestCase::insertPage 6 éve
MediaWikiTestResult.php 65adc37348 Make phpunit.php less hackish, and install the listener unconditionally 6 éve
MediaWikiTestRunner.php 65adc37348 Make phpunit.php less hackish, and install the listener unconditionally 6 éve
PHPUnit4And6Compat.php 9d78fc2c87 tests: Support passing null to setExpectedException() in compat layer 6 éve
README 8ef4c130e4 Update test documentation, fix broken links 9 éve
ResourceLoaderTestCase.php 6866cfec37 Simplify PHP by using ?? and ?: 6 éve
TODO 47623762fa format the tests/phpunit/TODO document for readability 10 éve
bootstrap.php 950368c7e8 Remove phpunit profiling. It doesn't make any sense 9 éve
phpunit.php 65adc37348 Make phpunit.php less hackish, and install the listener unconditionally 6 éve
run-tests.bat 23f69f10ed Per wikitech-l discussion: Move tests from maintenance/tests/ to tests/. They're not strictly maintenance scripts, and some people want to do a selective checkout that doesn't include the tests. There's still debate on whether we should include these in the release downloads, but we had a pretty firm consensus to move this. 14 éve
suite.xml dbe89abb9e languages: Add coverage for 'ar' and 'ml' normalize() 6 éve

README

== MediaWiki PHPUnit Tests ==

The unit tests for MediaWiki are implemented using the PHPUnit testing
framework and require PHPUnit to run.


=== WARNING ===

Some of the unit tests are DESTRUCTIVE and WILL ALTER YOUR WIKI'S CONTENTS.

DO NOT RUN THESE TESTS ON A PRODUCTION SYSTEM OR ON ANY SYSTEM WHERE YOU NEED
TO RETAIN YOUR DATA.


== Installation ==

If you used composer to install MediaWiki's dependencies PHPUnit will already be available, unless
you explicitly specified the --no-dev flag during the install. In this case just run "composer update".

Otherwise follow the installation instructions in the
PHPUnit Manual at:

https://phpunit.de/manual/current/en/installation.html


== Running tests ==

The tests are run from your operating system's command line.

Ensure that you are in the tests/phpunit directory of your MediaWiki
installation.


On Unix-like operating systems, the tests runs are controlled with a makefile.
Run command:

make help

for a full list of options for running tests.


On Windows-family operating systems, run the 'run-tests.bat' batch file.


=== Writing tests ===

A guide to writing PHP unit tests for MediaWiki can be found at:

https://www.mediawiki.org/wiki/Manual:PHP_unit_testing