Only whitelist it if QUnit is in that mode though (bug in QUnit?), caused it to repor...
authorKrinkle <krinkle@users.mediawiki.org>
Sun, 29 May 2011 04:19:51 +0000 (04:19 +0000)
committerKrinkle <krinkle@users.mediawiki.org>
Sun, 29 May 2011 04:19:51 +0000 (04:19 +0000)
tests/qunit/suites/resources/mediawiki/mediawiki.js

index c2a6af5..2b00088 100644 (file)
@@ -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(){