From 22752d8796515682a03e34e0d62ccdc4a9069556 Mon Sep 17 00:00:00 2001 From: Krinkle Date: Sun, 29 May 2011 04:19:51 +0000 Subject: [PATCH] Only whitelist it if QUnit is in that mode though (bug in QUnit?), caused it to report an error if not in noglobals mode. (Follow-up r89085) --- tests/qunit/suites/resources/mediawiki/mediawiki.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/qunit/suites/resources/mediawiki/mediawiki.js b/tests/qunit/suites/resources/mediawiki/mediawiki.js index c2a6af5c37..2b00088624 100644 --- a/tests/qunit/suites/resources/mediawiki/mediawiki.js +++ b/tests/qunit/suites/resources/mediawiki/mediawiki.js @@ -65,7 +65,9 @@ test( 'mw.Map', function(){ ok( window.anotherGlobalMapChecker, 'new mw.Map( true ) did store its values in the global window object' ); // Whitelist this global variable for QUnit 'noglobal' mode - QUnit.config.pollution.push( 'anotherGlobalMapChecker' ); + if ( QUnit.config.noglobals ) { + QUnit.config.pollution.push( 'anotherGlobalMapChecker' ); + } }); test( 'mw.config', function(){ -- 2.20.1