X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fspecials%2FSpecialJavaScriptTest.php;h=50a909f5e51944feeb8373d107c96921b5ad030e;hb=0d6ef1c0b20093e03e95a6b7f303c7a2de5de3af;hp=c984af8dec91106bb2c48b1d61077a5060e9a9da;hpb=0e56ff447bbb74df007f2573725baaa61ed2745c;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/specials/SpecialJavaScriptTest.php b/includes/specials/SpecialJavaScriptTest.php index c984af8dec..50a909f5e5 100644 --- a/includes/specials/SpecialJavaScriptTest.php +++ b/includes/specials/SpecialJavaScriptTest.php @@ -103,7 +103,7 @@ class SpecialJavaScriptTest extends SpecialPage { $query['only'] = 'scripts'; $startupContext = new ResourceLoaderContext( $rl, new FauxRequest( $query ) ); - $modules = $rl->getTestModuleNames( 'qunit' ); + $modules = $rl->getTestSuiteModuleNames(); // Disable autostart because we load modules asynchronously. By default, QUnit would start // at domready when there are no tests loaded and also fire 'QUnit.done' which then instructs @@ -111,7 +111,7 @@ class SpecialJavaScriptTest extends SpecialPage { $qunitConfig = 'QUnit.config.autostart = false;' . 'if (window.__karma__) {' // karma-qunit's use of autostart=false and QUnit.start conflicts with ours. - // Hack around this by replacing 'karma.loaded' with a no-op and perfom its duty of calling + // Hack around this by replacing 'karma.loaded' with a no-op and perform its duty of calling // `__karma__.start()` ourselves. See . . 'window.__karma__.loaded = function () {};' . '}'; @@ -170,11 +170,11 @@ JAVASCRIPT ); // Use 'raw' because QUnit loads before ResourceLoader initialises (omit mw.loader.state call) - // Use 'test' to ensure OutputPage doesn't use the "async" attribute because QUnit must + // Use 'sync' to ensure OutputPage doesn't use the "async" attribute because QUnit must // load before qunit/export. $scripts = $out->makeResourceLoaderLink( 'jquery.qunit', ResourceLoaderModule::TYPE_SCRIPTS, - [ 'raw' => true, 'sync' => true ] + [ 'raw' => '1', 'sync' => '1' ] ); $head = implode( "\n", [ $styles, $scripts ] );