--- a/toolkit/components/extensions/ExtensionXPCShellUtils.jsm
+++ b/toolkit/components/extensions/ExtensionXPCShellUtils.jsm
@@ -87,20 +87,20 @@ class ExtensionWrapper {
this.messageQueue.add([msg, ...args]);
this.checkMessages();
}
});
/* eslint-enable mozilla/balanced-listeners */
this.testScope.do_register_cleanup(() => {
if (this.state == "pending" || this.state == "running") {
- this.testScope.ok(false, "Extension left running at test shutdown");
+ this.testScope.equal(this.state, "unloaded", "Extension left running at test shutdown");
return this.unload();
} else if (extension.state == "unloading") {
- this.testScope.ok(false, "Extension not fully unloaded at test shutdown");
+ this.testScope.equal(this.state, "unloaded", "Extension not fully unloaded at test shutdown");
}
});
this.testScope.do_print(`Extension loaded`);
}
startup() {
if (this.state != "uninitialized") {
@@ -218,17 +218,17 @@ var ExtensionTestUtils = {
this.profileDir = scope.do_get_profile();
// We need to load at least one frame script into every message
// manager to ensure that the scriptable wrapper for its global gets
// created before we try to access it externally. If we don't, we
// fail sanity checks on debug builds the first time we try to
// create a wrapper, because we should never have a global without a
// cached wrapper.
- Services.mm.loadFrameScript("data:text/javascript,null", true);
+ Services.mm.loadFrameScript("data:text/javascript,//", true);
scope.do_register_cleanup(() => {
this.currentScope = null;
});
},
addonManagerStarted: false,