Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / xmlhttprequest / origin-whitelisting-ip-addresses.html
blob3abbb270f2b0f9a2d38efff48177d0142618cf34
1 <p>Tests origin whitelisting with IP addresses.</p>
2 <pre id="console"></pre>
3 <script>
4 testRunner.dumpAsText();
5 testRunner.waitUntilDone();
6 testRunner.addOriginAccessWhitelistEntry("http://localhost:8000", "http", "127.0.0.1", false);
8 function log(message)
10 document.getElementById('console').appendChild(document.createTextNode(message + '\n'));
13 var iframe = document.createElement("iframe");
14 document.body.appendChild(iframe);
15 iframe.src = "http://localhost:8000/xmlhttprequest/resources/origin-whitelisting-ip-address-test.html";
16 window.addEventListener("message", function(e) {
17 if (e.data == "DONE")
18 testRunner.notifyDone();
19 else
20 log(e.data);
21 }, false);
22 </script>