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
= [
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