Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / chrome / test / data / extensions / api_test / permissions / file_access_no / background.js
blob7191b52687931d79c2010caa8efebe99b2df7273
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 var callbackFail = chrome.test.callbackFail;
6 var callbackPass = chrome.test.callbackPass;
7 var expectedError =
8 "Invalid value for origin pattern file:///Invalid scheme.: *";
10 function test() {
11 chrome.permissions.request({"origins": ["file:///*"]},
12 callbackFail(expectedError, function(granted) {
13 chrome.test.assertFalse(granted);
14 chrome.permissions.getAll(callbackPass(function(permissions) {
15 chrome.test.assertEq([], permissions.origins);
16 chrome.test.succeed();
17 }));
18 }));
21 chrome.test.runTests([test]);