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 checks the "src" attribute is ignored when the
6 // "kEnableAdviewSrcAttribute" is missing.
8 function runTests(guestURL) {
11 var adview = document.getElementsByTagName("adview")[0];
13 adview.setAttribute("src", guestURL);
15 // Timeout is necessary to give the mutation observers a chance to fire.
16 // http://lists.w3.org/Archives/Public/public-webapps/2011JulSep/1622.html
17 setTimeout(function() {
18 chrome.test.assertEq("", adview.getAttribute("src"));
19 chrome.test.assertEq(undefined, adview['src']);
20 chrome.test.assertEq(undefined, adview.src);
21 console.log("Properties and attributes are inactive.");
22 chrome.test.succeed();
28 window.onload = function() {
29 chrome.test.getConfig(function(config) {
30 var guestURL = 'http://localhost:' + config.testServer.port +
31 '/extensions/platform_apps/ad_view/ad_network_site/testsdk.html';