Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(499)

Unified Diff: third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/xss-DENIED-top-navigation-without-user-gesture.html

Issue 2425663002: Add an error page for resources blocked via XSS Auditor. (Closed)
Patch Set: Test. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/xss-DENIED-top-navigation-without-user-gesture.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/xss-DENIED-top-navigation-without-user-gesture.html b/third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/xss-DENIED-top-navigation-without-user-gesture.html
index a2cdc9496450a459d055e4355f2145b35765ef50..84d404b9f94ecf2074ba77389af2690c21fcb385 100644
--- a/third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/xss-DENIED-top-navigation-without-user-gesture.html
+++ b/third_party/WebKit/LayoutTests/http/tests/security/frameNavigation/xss-DENIED-top-navigation-without-user-gesture.html
@@ -4,10 +4,19 @@
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.dumpChildFramesAsText();
- testRunner.setDumpConsoleMessages(false);
+ testRunner.setDumpConsoleMessages(true);
+ testRunner.waitUntilDone();
}
+
if (window.internals)
- internals.runtimeFlags.setFramebustingNeedsSameOriginOrUserGesture(true);
+ internals.runtimeFlags.setFramebustingNeedsSameOriginOrUserGesture = true;
+
+window.addEventListener("message", e => {
+ if (e.data == "PASS")
+ testRunner.notifyDone();
+ else
+ testRunner.testFailed("'top.location' didn't throw.");
+});
</script>
</head>
<body>

Powered by Google App Engine
This is Rietveld 408576698