| OLD | NEW |
| (Empty) | |
| 1 <!DOCTYPE html> |
| 2 <html> |
| 3 <head> |
| 4 <script src="../../../resources/js-test.js"></script> |
| 5 <script> |
| 6 // Note: this test must indirect through a file:// iframe, since the original te
st page is |
| 7 // created with an origin that has universal access. |
| 8 |
| 9 jsTestIsAsync = true; |
| 10 |
| 11 description('Test that web settings are applied early enough when creating a new
view: if the settings are applied to late, a new window created by a file:// UR
L will have universal access even if universal access is not enabled.'); |
| 12 |
| 13 if (window.testRunner) { |
| 14 testRunner.setAllowUniversalAccessFromFileURLs(false); |
| 15 testRunner.setAllowFileAccessFromFileURLs(false); |
| 16 testRunner.setCanOpenWindows(true); |
| 17 } |
| 18 |
| 19 window.addEventListener('message', function (e) { |
| 20 if (e.data) |
| 21 testPassed(e.data); |
| 22 else |
| 23 testFailed('accessing newWindow.document did not throw!'); |
| 24 finishJSTest(); |
| 25 }); |
| 26 </script> |
| 27 </head> |
| 28 <body> |
| 29 <iframe src="resources/file-origin-window-open-frame.html"></iframe> |
| 30 </body> |
| 31 </html> |
| OLD | NEW |