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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/security/document-domain-canonicalizes.html

Issue 2447293002: Don't call lower() on KURL protocol/host (Closed)
Patch Set: add canonicalization layout 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 unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <head>
3 <script src="/resources/testharness.js"></script>
4 <script src="/resources/testharnessreport.js"></script>
5 <script>
6 </script>
7 </head>
8 <body>
9
10 <script>
11 if (document.location.hostname == "127.0.0.1") {
12 document.location.hostname = "subdomain.example.test";
13 } else {
14 test(function() {
15 document.domain = 'EXAMPLE.TEST';
16 assert_equals(document.domain, 'example.test');
17
18 document.domain = 'subdomain.eXamPle.tEst';
19 assert_equals(document.domain, 'subdomain.example.test');
20 }, 'document.domain goes through proper canonicalization.');
21 }
22 </script>
23
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698