MediaWiki
REL1_22
|
00001 == MediaWiki PHPUnit Tests == 00002 00003 The unit tests for MediaWiki are implemented using the PHPUnit testing 00004 framework and require PHPUnit to run. 00005 00006 00007 === WARNING === 00008 00009 Some of the unit tests are DESTRUCTIVE and WILL ALTER YOUR WIKI'S CONTENTS. 00010 00011 DO NOT RUN THESE TESTS ON A PRODUCTION SYSTEM OR ON ANY SYSTEM WHERE YOU NEED 00012 TO RETAIN YOUR DATA. 00013 00014 00015 == Installation == 00016 00017 If PHPUnit is not installed, follow the installation instructions in the 00018 PHPUnit Manual at: 00019 00020 http://www.phpunit.de/manual/current/en/installation.html 00021 00022 - or - 00023 00024 On Unix-like operating systems, run: 00025 00026 make install 00027 00028 00029 == Running tests == 00030 00031 The tests are run from your operating system's command line. 00032 00033 Ensure that you are in the tests/phpunit directory of your MediaWiki 00034 installation. 00035 00036 00037 On Unix-like operating systems, the tests runs are controlled with a makefile. 00038 Run command: 00039 00040 make help 00041 00042 for a full list of options for running tests. 00043 00044 00045 On Windows-family operating systems, run the 'run-tests.bat' batch file. 00046 00047 00048 === Writing tests === 00049 00050 A guide to writing unit tests for MediaWiki can be found at: 00051 00052 http://mediawiki.org/wiki/Unit_Testing 00053