Bug 1270306 - [webext] extension.isAllowedFileSchemeAccess should return null. r=kmag
authorChristopher Grebs <cgrebs@mozilla.com>
Tue, 24 May 2016 21:03:46 +0200
changeset 338058 661db976e5e8685e129efa82df0ce21bb5eaed15
parent 338057 0928a16792af6f0a947b1fdca5b12d16b84eaca0
child 338059 a771679df23c7744c7d51237291decedaf89f8a4
push id6249
push userjlund@mozilla.com
push dateMon, 01 Aug 2016 13:59:36 +0000
treeherdermozilla-beta@bad9d4f5bf7e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskmag
bugs1270306
milestone49.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 1270306 - [webext] extension.isAllowedFileSchemeAccess should return null. r=kmag
toolkit/components/extensions/ext-extension.js
toolkit/components/extensions/test/mochitest/test_ext_extension.html
--- a/toolkit/components/extensions/ext-extension.js
+++ b/toolkit/components/extensions/ext-extension.js
@@ -35,14 +35,14 @@ extensions.registerSchemaAPI("extension"
         return context.incognito;
       },
 
       isAllowedIncognitoAccess() {
         return Promise.resolve(true);
       },
 
       isAllowedFileSchemeAccess() {
-        return Promise.resolve(true);
+        return Promise.resolve(false);
       },
     },
   };
 });
 
--- a/toolkit/components/extensions/test/mochitest/test_ext_extension.html
+++ b/toolkit/components/extensions/test/mochitest/test_ext_extension.html
@@ -31,17 +31,17 @@ add_task(function* test_is_allowed_incog
   yield extension.awaitFinish("isAllowedIncognitoAccess");
   yield extension.unload();
   info("extension unloaded");
 });
 
 add_task(function* test_is_allowed_file_scheme_access() {
   function backgroundScript() {
     browser.extension.isAllowedFileSchemeAccess().then(isAllowedFileSchemeAccess => {
-      browser.test.assertEq(true, isAllowedFileSchemeAccess, "isAllowedFileSchemeAccess is true");
+      browser.test.assertEq(false, isAllowedFileSchemeAccess, "isAllowedFileSchemeAccess is false");
       browser.test.notifyPass("isAllowedFileSchemeAccess");
     });
   }
 
   let extension = ExtensionTestUtils.loadExtension({
     background: `(${backgroundScript})()`,
     manifest: {},
   });