Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / misc / javascript-url-stop-loaders.html
blob1063e87738d3fd6a94d5c1b8e3866b554cff6bde
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <script src="/js-test-resources/js-test.js"></script>
5 <script type="text/javascript">
6 var str = "<script type='text/javascript' src='http://127.0.0.1:8000/misc/resources/hang-connection.php'><" + "/script>";
8 function loadFirst()
10 document.getElementById("ad").src = "javascript: window.parent.str";
13 function finish()
15 gc();
16 if (window.testRunner)
17 testRunner.notifyDone();
20 function loadSecond()
22 document.getElementById("ad").src = "javascript: '<!DOCTYPE html><script>window.parent.finish();<" + "/script>'";
25 if (window.testRunner) {
26 testRunner.waitUntilDone();
27 testRunner.dumpAsText();
30 setTimeout("loadFirst();", 0);
31 setTimeout("loadSecond();", 0);
32 </script>
33 </head>
34 <body>
35 <p>This test checks whether loading a JavaScript URL cancels loaders. If it fails, it will give an assertion failure in Debug builds.</p>
36 <iframe id="ad"></iframe>
37 </body>
38 </html>