Bug 1394553 - Part 2: Prune the GRANTED_WITHOUT_USER_PROMPT list r=aswan
authorTomislav Jovanovic <tomica@gmail.com>
Mon, 04 Sep 2017 21:51:25 +0200
changeset 429647 9c580f81df29f97b396c76fa5f2af8e41c698700
parent 429646 2b51c082d3f46697b6c3b70214b468fdb5098e93
child 429648 e9816be61b49fd249b854967160f91ee361c7a9d
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaswan
bugs1394553
milestone57.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 1394553 - Part 2: Prune the GRANTED_WITHOUT_USER_PROMPT list r=aswan MozReview-Commit-ID: 844ITHXaauA
toolkit/components/extensions/schemas/downloads.json
toolkit/components/extensions/test/xpcshell/test_ext_permissions.js
--- a/toolkit/components/extensions/schemas/downloads.json
+++ b/toolkit/components/extensions/schemas/downloads.json
@@ -3,18 +3,17 @@
     "namespace": "manifest",
     "types": [
       {
         "$extend": "Permission",
         "choices": [{
           "type": "string",
           "enum": [
             "downloads",
-            "downloads.open",
-            "downloads.shelf"
+            "downloads.open"
           ]
         }]
       }
     ]
   },
   {
     "namespace": "downloads",
     "permissions": ["downloads"],
--- a/toolkit/components/extensions/test/xpcshell/test_ext_permissions.js
+++ b/toolkit/components/extensions/test/xpcshell/test_ext_permissions.js
@@ -367,27 +367,23 @@ add_task(async function test_alreadyGran
   await extension.unload();
 });
 
 // IMPORTANT: Do not change this list without review from a Web Extensions peer!
 
 const GRANTED_WITHOUT_USER_PROMPT = [
   "activeTab",
   "alarms",
-  "browsingData",
   "contextMenus",
   "contextualIdentities",
   "cookies",
-  "downloads.open",
-  "downloads.shelf",
   "geckoProfiler",
   "identity",
   "idle",
   "menus",
-  "proxy",
   "storage",
   "theme",
   "webRequest",
   "webRequestBlocking",
 ];
 
 add_task(function test_permissions_have_localization_strings() {
   const ns = Schemas.getNamespace("manifest");
@@ -396,16 +392,17 @@ add_task(function test_permissions_have_
   const optional = ns.get("OptionalPermission").choices;
 
   const bundle = Services.strings.createBundle(BROWSER_PROPERTIES);
 
   for (const choice of permissions.concat(optional)) {
     for (const perm of choice.enumeration || []) {
       try {
         const str = bundle.GetStringFromName(`webextPerms.description.${perm}`);
+
         ok(str.length, `Found localization string for '${perm}' permission`);
       } catch (e) {
         ok(GRANTED_WITHOUT_USER_PROMPT.includes(perm),
           `Permission '${perm}' intentionally granted without prompting the user`);
       }
     }
   }
 });