Bug 1915045 Ensure decode tasks are scheduled on BufferingState::Enter() r=media...
[gecko.git] / js / xpconnect / tests / unit / test_ComponentEnvironment.js
blob1d2c474ffd7e675de5a025415896a84271841e5e
1 let tgt = {};
3 Services.prefs.setBoolPref("security.allow_eval_with_system_principal", true);
4 registerCleanupFunction(() => {
5   Services.prefs.clearUserPref("security.allow_eval_with_system_principal");
6 });
8 const a = ChromeUtils.import("resource://test/environment_script.js", tgt);
9 const b = ChromeUtils.import("resource://test/environment_checkscript.jsm", tgt);
11 const isShared = Cu.getGlobalForObject(a) === Cu.getGlobalForObject(b);
14 // Components should not share namespace
15 if (isShared) {
16   todo_check_eq(tgt.bound, "");
17   Assert.equal(tgt.bound, "ei,fo,", "Modules should have no shared non-eval bindings");
18 } else {
19   Assert.equal(tgt.bound, "", "Modules should have no shared bindings");