Bug 1535337 - Part 3: Don't set prefs inside browser_blockingServiceWorkers.js from the content process and just pass them through extraPrefs; r=baku
authorEhsan Akhgari <ehsan@mozilla.com>
Sat, 16 Mar 2019 02:42:42 +0000
changeset 525364 3c2169f7665e64eb2de2a86543afe2a41bdd1c25
parent 525363 81d4d461ab15c506dcc9baef1341024d6410b7b8
child 525365 2717903072b67945042d543901238c491e5d20ca
push id2032
push userffxbld-merge
push dateMon, 13 May 2019 09:36:57 +0000
treeherdermozilla-release@455c1065dcbe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbaku
bugs1535337
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1535337 - Part 3: Don't set prefs inside browser_blockingServiceWorkers.js from the content process and just pass them through extraPrefs; r=baku Depends on D23509 Differential Revision: https://phabricator.services.mozilla.com/D23510
toolkit/components/antitracking/test/browser/browser_blockingServiceWorkers.js
--- a/toolkit/components/antitracking/test/browser/browser_blockingServiceWorkers.js
+++ b/toolkit/components/antitracking/test/browser/browser_blockingServiceWorkers.js
@@ -15,23 +15,16 @@ AntiTracking.runTest("ServiceWorkers",
   },
   [["dom.serviceWorkers.exemptFromPerDomainMax", true],
    ["dom.ipc.processCount", 1],
    ["dom.serviceWorkers.enabled", true],
    ["dom.serviceWorkers.testing.enabled", true]]);
 
 AntiTracking.runTest("ServiceWorkers and Storage Access API",
   async _ => {
-    await SpecialPowers.pushPrefEnv({"set": [
-       ["dom.serviceWorkers.exemptFromPerDomainMax", true],
-       ["dom.ipc.processCount", 1],
-       ["dom.serviceWorkers.enabled", true],
-       ["dom.serviceWorkers.testing.enabled", true],
-    ]});
-
     /* import-globals-from storageAccessAPIHelpers.js */
     await noStorageAccessInitially();
 
     await navigator.serviceWorker.register("empty.js").then(
       _ => { ok(false, "ServiceWorker cannot be used!"); },
       _ => { ok(true, "ServiceWorker cannot be used!"); }).
       catch(e => ok(false, "Promise rejected: " + e));
 
@@ -48,23 +41,16 @@ AntiTracking.runTest("ServiceWorkers and
         reg => { ok(true, "ServiceWorker can be used!"); return reg; },
         _ => { ok(false, "ServiceWorker cannot be used! " + _); }).then(
         reg => reg.unregister(),
         _ => { ok(false, "unregister failed"); }).
         catch(e => ok(false, "Promise rejected: " + e));
     }
   },
   async _ => {
-    await SpecialPowers.pushPrefEnv({"set": [
-       ["dom.serviceWorkers.exemptFromPerDomainMax", true],
-       ["dom.ipc.processCount", 1],
-       ["dom.serviceWorkers.enabled", true],
-       ["dom.serviceWorkers.testing.enabled", true],
-    ]});
-
     /* import-globals-from storageAccessAPIHelpers.js */
     if (allowListed) {
       await hasStorageAccessInitially();
     } else {
       await noStorageAccessInitially();
     }
 
     await navigator.serviceWorker.register("empty.js").then(