3 * This test suite runs unit tests registered by extensions.
4 * See https://www.mediawiki.org/wiki/Manual:Hooks/UnitTestsList for details of
5 * how to register your tests.
8 class ExtensionsTestSuite
extends PHPUnit_Framework_TestSuite
{
9 public function __construct() {
10 parent
::__construct();
12 wfRunHooks( 'UnitTestsList', array( &$files ) );
13 foreach ( $files as $file ) {
14 $this->addTestFile( $file );
16 if ( !count( $files ) ) {
17 $this->addTest( new DummyExtensionsTest( 'testNothing' ) );
21 public static function suite() {
27 * Needed to avoid warnings like 'No tests found in class "ExtensionsTestSuite".'
28 * when no extensions with tests are used.
30 class DummyExtensionsTest
extends MediaWikiTestCase
{
31 public function testNothing() {
32 $this->assertTrue( true );