3 <script src="../resources/cross-frame-access.js"></script>
7 window.onload = function()
9 if (window.testRunner) {
10 testRunner.dumpAsText();
11 testRunner.waitUntilDone();
12 testRunner.setCanOpenWindows();
15 var url = "javascript:\"<html><head><scr" + "ipt>window.onload = function() { window.opener.postMessage('run test', '*'); }</scr" + "ipt></head><body><p>Opened Frame</p><p id='accessMe'>FAIL</p></body></html>\"";
16 openedWindow = window.open(url);
18 window.addEventListener('message', function ()
21 closeWindowAndNotifyDone(openedWindow);
28 openedWindow.document.getElementById('accessMe').innerHTML = "PASS: Access to a window opened with a javascript: URL was allowed!";
29 log("PASS: Access to a window opened with a javascript: URL was allowed!");
31 log("FAIL: Access to a window opened with a javascript: URL was denied.");
38 <pre id="console"></pre>