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

Unified Diff: LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html

Issue 19932002: Throw exceptions on all failed cross-origin access checks. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: test. Created 7 years, 5 months 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: LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html
diff --git a/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html b/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html
index 0ead40d4a3e7a02a15d7650107330aac9ed27f40..11cb8023591d7f376ac744efddb5d4928686894d 100644
--- a/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html
+++ b/LayoutTests/http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html
@@ -6,10 +6,11 @@ if (window.testRunner)
window.onload = function() {
var frame = document.getElementsByTagName("iframe")[0];
- var secret = frame.contentWindow.secret;
- if (secret)
+ try {
+ var secret = frame.contentWindow.secret;
alert("FAIL: Iframe was not in a unique origin: " + secret);
- else
+ } catch (e) {
alert("PASS: Iframe was in a unique origin");
+ }
};
</script>

Powered by Google App Engine
This is Rietveld 408576698