summaryrefslogtreecommitdiffstats
path: root/toolkit/mozapps/extensions/test/xpcshell
diff options
context:
space:
mode:
authorJustOff <Off.Just.Off@gmail.com>2018-04-23 14:52:50 +0300
committerJustOff <Off.Just.Off@gmail.com>2018-04-23 14:52:50 +0300
commitbe2b3635ad7f21582a5cfd5a25fc4ec41653c1c7 (patch)
tree2efcee5cff17dc0dd8cf9237ddaede584c7b22b1 /toolkit/mozapps/extensions/test/xpcshell
parentbccb9c1708f007ada1ea8c4879db88a587f0a450 (diff)
downloadUXP-be2b3635ad7f21582a5cfd5a25fc4ec41653c1c7.tar
UXP-be2b3635ad7f21582a5cfd5a25fc4ec41653c1c7.tar.gz
UXP-be2b3635ad7f21582a5cfd5a25fc4ec41653c1c7.tar.lz
UXP-be2b3635ad7f21582a5cfd5a25fc4ec41653c1c7.tar.xz
UXP-be2b3635ad7f21582a5cfd5a25fc4ec41653c1c7.zip
Fix accessing the bootstrap methods when they are declared in the new lexical scope
Diffstat (limited to 'toolkit/mozapps/extensions/test/xpcshell')
-rw-r--r--toolkit/mozapps/extensions/test/xpcshell/test_bootstrap_const.js17
-rw-r--r--toolkit/mozapps/extensions/test/xpcshell/xpcshell-shared.ini1
2 files changed, 18 insertions, 0 deletions
diff --git a/toolkit/mozapps/extensions/test/xpcshell/test_bootstrap_const.js b/toolkit/mozapps/extensions/test/xpcshell/test_bootstrap_const.js
new file mode 100644
index 000000000..fb02b59be
--- /dev/null
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_bootstrap_const.js
@@ -0,0 +1,17 @@
+/* Any copyright is dedicated to the Public Domain.
+ * http://creativecommons.org/publicdomain/zero/1.0/
+ */
+
+createAppInfo("xpcshell@tests.mozilla.org", "XPCShell", "1", "1");
+startupManager();
+
+add_task(function*() {
+ let sawInstall = false;
+ Services.obs.addObserver(function() {
+ sawInstall = true;
+ }, "addon-install", false);
+
+ yield promiseInstallAllFiles([do_get_addon("test_bootstrap_const")]);
+
+ ok(sawInstall);
+}); \ No newline at end of file
diff --git a/toolkit/mozapps/extensions/test/xpcshell/xpcshell-shared.ini b/toolkit/mozapps/extensions/test/xpcshell/xpcshell-shared.ini
index bab072e83..2a12f147a 100644
--- a/toolkit/mozapps/extensions/test/xpcshell/xpcshell-shared.ini
+++ b/toolkit/mozapps/extensions/test/xpcshell/xpcshell-shared.ini
@@ -29,6 +29,7 @@ skip-if = os == "android"
[test_bootstrap.js]
# Bug 676992: test consistently hangs on Android
skip-if = os == "android"
+[test_bootstrap_const.js]
[test_bootstrap_resource.js]
[test_bug299716.js]
# Bug 676992: test consistently hangs on Android