MCPcopy
hub / github.com/dataarts/dat.gui / checkPollution

Function checkPollution

tests/qunit.js:958–971  ·  view source on GitHub ↗
( name )

Source from the content-addressed store, hash-verified

956}
957
958function checkPollution( name ) {
959 var old = config.pollution;
960 saveGlobal();
961
962 var newGlobals = diff( config.pollution, old );
963 if ( newGlobals.length > 0 ) {
964 ok( false, "Introduced global variable(s): " + newGlobals.join(", ") );
965 }
966
967 var deletedGlobals = diff( old, config.pollution );
968 if ( deletedGlobals.length > 0 ) {
969 ok( false, "Deleted global variable(s): " + deletedGlobals.join(", ") );
970 }
971}
972
973// returns a new Array with the elements that are in a but not in b
974function diff( a, b ) {

Callers 1

qunit.jsFile · 0.85

Calls 2

saveGlobalFunction · 0.85
diffFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…