Do not announce robot account token before account ID is available
[chromium-blink-merge.git] / chrome / test / data / extensions / platform_apps / web_view / nopermission / embedder.js
blobe7247a233226deea3f20826656b71582d80773fb
1 // Copyright 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 // This test verifies that the <webview> API is undefined if the webview
6 // permission is not specified in the manifest file.
7 function testAPIMethodExistence() {
8 var apiMethodsToCheck = [
9 'back',
10 'canGoBack',
11 'canGoForward',
12 'forward',
13 'getProcessId',
14 'go',
15 'reload',
16 'stop',
17 'terminate'
19 var webview = document.createElement('webview');
20 for (var i = 0; i < apiMethodsToCheck.length; ++i) {
21 chrome.test.assertEq('undefined',
22 typeof webview[apiMethodsToCheck[i]]);
25 // Check contentWindow.
26 chrome.test.assertEq('undefined', typeof webview.contentWindow);
27 chrome.test.succeed();
30 chrome.test.runTests([
31 testAPIMethodExistence
32 ]);