chromium/third_party/blink/web_tests/http/tests/security/cross-origin-window-event-exception.html

<!DOCTYPE html>
<html>
<head>
</head>
<body>
    <iframe src="http://localhost:8080/"></iframe>
    <script src="/js-test-resources/js-test.js"></script>
    <script>
        description("Cross-origin access to 'window.event' should throw a SecurityError.");
        window.jsTestIsAsync = true;
        
        var frame = document.querySelector('iframe');
        window.onload = function () {
            shouldThrow("frame.contentWindow.event", '"SecurityError: Failed to read a named property \'event\' from \'Window\': Blocked a frame with origin \\"http://127.0.0.1:8000\\" from accessing a cross-origin frame."');
            shouldThrow("frame.contentWindow.event = 1;", '"SecurityError: Failed to set a named property \'event\' on \'Window\': Blocked a frame with origin \\"http://127.0.0.1:8000\\" from accessing a cross-origin frame."');
            finishJSTest();
        };
    </script>
</body>
</html>