Bug 1494145 follow-up: Add the contentblocking prefs to one more test as well a=test-only

This commit is contained in:
Ehsan Akhgari 2018-09-27 03:01:52 -04:00
parent baa64eea9e
commit 273054f273

View File

@ -12,11 +12,16 @@ XPCOMUtils.defineLazyServiceGetter(Services, "cookiemgr",
"nsICookieManager");
function restore_prefs() {
Services.prefs.clearUserPref("browser.contentblocking.enabled");
Services.prefs.clearUserPref("browser.contentblocking.ui.enabled");
Services.prefs.clearUserPref("network.cookie.cookieBehavior");
Services.prefs.clearUserPref("network.cookie.lifetimePolicy");
}
registerCleanupFunction(restore_prefs);
Services.prefs.setBoolPref("browser.contentblocking.enabled", true);
Services.prefs.setBoolPref("browser.contentblocking.ui.enabled", true);
async function fake_profile_change() {
await new Promise(resolve => {
Services.obs.addObserver(function waitForDBClose() {