test: register them using the 'UnitTestsList' hook

Change-Id: I32863986ebf1a49f5c546ca98e9b558b9c4a2850
This commit is contained in:
Antoine Musso 2013-11-07 11:32:01 +01:00
parent 738fdf3130
commit 394e78b8fd

View file

@ -76,6 +76,10 @@ $wgHooks['CentralAuthAutoCreate'][] = 'TitleBlacklistHooks::centralAuthAutoCreat
$wgHooks['EditFilter'][] = 'TitleBlacklistHooks::validateBlacklist';
$wgHooks['ArticleSaveComplete'][] = 'TitleBlacklistHooks::clearBlacklist';
$wgHooks['UserCreateForm'][] = 'TitleBlacklistHooks::addOverrideCheckbox';
$wgHooks['UnitTestsList'][] = function( &$files ) {
$files += glob( __DIR__ . '/tests/*Test.php' );
return true;
};
$wgResourceModules['mediawiki.api.titleblacklist'] = array(
'scripts' => 'mediawiki.api.titleblacklist.js',