| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 </head> | 4 </head> |
| 5 <body> | 5 <body> |
| 6 <iframe src="http://localhost:8080/"></iframe> | 6 <iframe src="http://localhost:8080/"></iframe> |
| 7 <script src="/js-test-resources/js-test-pre.js"></script> | 7 <script src="/js-test-resources/js-test-pre.js"></script> |
| 8 <script> | 8 <script> |
| 9 description("Cross-origin access to 'window.event' should throw a Securi
tyError."); | 9 description("Cross-origin access to 'window.event' should throw a Securi
tyError."); |
| 10 window.jsTestIsAsync = true; | 10 window.jsTestIsAsync = true; |
| 11 | 11 |
| 12 var frame = document.querySelector('iframe'); | 12 var frame = document.querySelector('iframe'); |
| 13 window.onload = function () { | 13 window.onload = function () { |
| 14 shouldThrow("frame.contentWindow.event", '"SecurityError: Blocked a
frame with origin \\"http://127.0.0.1:8000\\" from accessing a cross-origin fram
e."'); | 14 shouldThrow("frame.contentWindow.event", '"SecurityError: Blocked a
frame with origin \\"http://127.0.0.1:8000\\" from accessing a cross-origin fram
e."'); |
| 15 shouldThrow("frame.contentWindow.event = 1;", '"SecurityError: Block
ed a frame with origin \\"http://127.0.0.1:8000\\" from accessing a cross-origin
frame."'); | 15 shouldThrow("frame.contentWindow.event = 1;", '"SecurityError: Block
ed a frame with origin \\"http://127.0.0.1:8000\\" from accessing a cross-origin
frame."'); |
| 16 finishJSTest(); | 16 finishJSTest(); |
| 17 }; | 17 }; |
| 18 </script> | 18 </script> |
| 19 <script src="/js-test-resources/js-test-post.js"></script> | |
| 20 </body> | 19 </body> |
| 21 </html> | 20 </html> |
| OLD | NEW |