|
1 <!DOCTYPE HTML> |
|
2 <html> |
|
3 <!-- |
|
4 https://bugzilla.mozilla.org/show_bug.cgi?id=419132 |
|
5 --> |
|
6 <head> |
|
7 <title>Test for Bug 419132</title> |
|
8 <script type="application/javascript" src="/MochiKit/MochiKit.js"></script> |
|
9 <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> |
|
10 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/> |
|
11 </head> |
|
12 <body> |
|
13 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=419132">Mozilla Bug 419132</a> |
|
14 <p id="display"></p> |
|
15 <div id="content" style="display: none"> |
|
16 |
|
17 </div> |
|
18 <iframe id="i"></iframe> |
|
19 <pre id="test"> |
|
20 <script type="application/javascript"> |
|
21 |
|
22 /** Test for Bug 419132 **/ |
|
23 |
|
24 SimpleTest.waitForExplicitFinish(); |
|
25 addLoadEvent(function() { |
|
26 var iframe = document.getElementById("i"); |
|
27 var loadCounts = 4; |
|
28 iframe.addEventListener("load", function() { |
|
29 if (--loadCounts == 0) { |
|
30 ok(true, "This is a mochikit version of a crash test. To complete is to pass."); |
|
31 SimpleTest.finish(); |
|
32 } else { |
|
33 // Garbage collect after every other load |
|
34 if ((loadCounts % 2) == 1) { |
|
35 SpecialPowers.gc(); |
|
36 } |
|
37 setTimeout(function() { |
|
38 iframe.contentWindow.location.reload(); |
|
39 }, 0); |
|
40 } |
|
41 }, false); |
|
42 iframe.src = "bug419132.html"; |
|
43 }); |
|
44 |
|
45 </script> |
|
46 </pre> |
|
47 </body> |
|
48 </html> |