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

Unified Diff: LayoutTests/http/tests/htmlimports/import-cors-credentials.html

Issue 196043002: HTML Imports: Send credentials for same origin requests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Landing again with another fix Created 6 years, 9 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
« no previous file with comments | « no previous file | LayoutTests/http/tests/htmlimports/import-cors-credentials-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/htmlimports/import-cors-credentials.html
diff --git a/LayoutTests/http/tests/htmlimports/import-cors-credentials.html b/LayoutTests/http/tests/htmlimports/import-cors-credentials.html
new file mode 100644
index 0000000000000000000000000000000000000000..beb90273443369e7392ef3ebcf3ac77ddd1d5dae
--- /dev/null
+++ b/LayoutTests/http/tests/htmlimports/import-cors-credentials.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<script src="/js-test-resources/js-test.js"></script>
+<script>
+document.cookie = "key=HelloCredentials";
+</script>
+<link id="sameOrigin" rel="import" href="resources/cookie-match.cgi?key=HelloCredentials">
+<link id="crossOrigin" rel="import" href="http://localhost:8080/htmlimports/resources/cookie-match.cgi">
+<link id="fromSameToCrossOrigin" rel="import" href="resources/having-cookie-match-8080.html">
+<link id="fromCrossToSameOrigin" rel="import" href="http://localhost:8080/htmlimports/resources/having-cookie-match-same.cgi">
+<script>
+if (window.testRunner)
+ testRunner.dumpAsText();
+
+shouldBeEqualToString("sameOrigin.import.body.innerHTML", "PASS");
+shouldBeEqualToString("crossOrigin.import.body.innerHTML", "PASS");
+shouldBeEqualToString("fromSameToCrossOrigin.import.getElementById('crossOrigin').import.body.innerHTML", "PASS");
+shouldBeEqualToString("fromCrossToSameOrigin.import.getElementById('sameOrigin').import.body.innerHTML", "PASS");
+</script>
« no previous file with comments | « no previous file | LayoutTests/http/tests/htmlimports/import-cors-credentials-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698