summaryrefslogtreecommitdiffstats
path: root/services/sync/tests/unit/test_addons_engine.js
diff options
context:
space:
mode:
Diffstat (limited to 'services/sync/tests/unit/test_addons_engine.js')
-rw-r--r--services/sync/tests/unit/test_addons_engine.js17
1 files changed, 11 insertions, 6 deletions
diff --git a/services/sync/tests/unit/test_addons_engine.js b/services/sync/tests/unit/test_addons_engine.js
index 64e4e32e8..ca2e4bd96 100644
--- a/services/sync/tests/unit/test_addons_engine.js
+++ b/services/sync/tests/unit/test_addons_engine.js
@@ -13,20 +13,19 @@ Cu.import("resource://services-sync/service.js");
Cu.import("resource://services-sync/util.js");
Cu.import("resource://testing-common/services/sync/utils.js");
-var prefs = new Preferences();
+let prefs = new Preferences();
prefs.set("extensions.getAddons.get.url",
"http://localhost:8888/search/guid:%IDS%");
-prefs.set("extensions.install.requireSecureOrigin", false);
loadAddonTestFunctions();
startupManager();
-var engineManager = Service.engineManager;
+let engineManager = Service.engineManager;
engineManager.register(AddonsEngine);
-var engine = engineManager.get("addons");
-var reconciler = engine._reconciler;
-var tracker = engine._tracker;
+let engine = engineManager.get("addons");
+let reconciler = engine._reconciler;
+let tracker = engine._tracker;
function advance_test() {
reconciler._addons = {};
@@ -36,6 +35,8 @@ function advance_test() {
reconciler.saveState(null, cb);
cb.wait();
+ Svc.Prefs.reset("addons.ignoreRepositoryChecking");
+
run_next_test();
}
@@ -103,6 +104,7 @@ add_test(function test_get_changed_ids() {
tracker.clearChangedIDs();
_("Ensure reconciler changes are populated.");
+ Svc.Prefs.set("addons.ignoreRepositoryChecking", true);
let addon = installAddon("test_bootstrap1_1");
tracker.clearChangedIDs(); // Just in case.
changes = engine.getChangedIDs();
@@ -149,6 +151,9 @@ add_test(function test_disabled_install_semantics() {
// This is essentially a test for bug 712542, which snuck into the original
// add-on sync drop. It ensures that when an add-on is installed that the
// disabled state and incoming syncGUID is preserved, even on the next sync.
+
+ Svc.Prefs.set("addons.ignoreRepositoryChecking", true);
+
const USER = "foo";
const PASSWORD = "password";
const PASSPHRASE = "abcdeabcdeabcdeabcdeabcdea";