OLD | NEW |
| (Empty) |
1 <html> | |
2 <script src="../../resources/js-test.js"></script> | |
3 <body onload="runTest()"> | |
4 <div id="console"></div> | |
5 <form id="form1" style="display:none" method="post" target="test" action
="http://anything.com"></form> | |
6 <script> | |
7 if (window.testRunner) | |
8 { | |
9 testRunner.dumpAsText(); | |
10 testRunner.waitUntilDone(); | |
11 } | |
12 | |
13 function runTest() | |
14 { | |
15 document.getElementById('form1').submit(); | |
16 | |
17 if (window.testRunner) | |
18 testRunner.notifyDone(); | |
19 document.getElementById('console').innerHTML = 'PASS'; | |
20 } | |
21 | |
22 count = 0; | |
23 document.addEventListener("beforeload", function(event) { | |
24 event.preventDefault(); | |
25 count = count + 1; | |
26 if (count == 2) | |
27 { | |
28 document.body.removeChild(document.getElementById('test')); | |
29 gc(); | |
30 document.body.offsetTop; | |
31 } | |
32 }, true); | |
33 </script> | |
34 <iframe id="test" src="about:blank"></iframe> | |
35 </body> | |
36 </html> | |
37 | |
OLD | NEW |