| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head></head> | 2 <head></head> |
| 3 <body> | 3 <body> |
| 4 <p id="description"></p> | 4 <p id="description"></p> |
| 5 <br> | 5 <br> |
| 6 <iframe id="subframe"></iframe> | 6 <iframe name="subframe"></iframe> |
| 7 <br> | 7 <br> |
| 8 This tests that window.frames.length does not crash the browser after the | 8 This tests that window.frames.length does not crash the browser after the |
| 9 frame navigates away from the current page. You should see "SUCCESS" below | 9 frame navigates away from the current page. You should see "SUCCESS" below |
| 10 once the test completes. | 10 once the test completes. |
| 11 <br> | 11 <br> |
| 12 <div id="status">Test in progress...</div> | 12 <div id="status">Test in progress...</div> |
| 13 | 13 |
| 14 <script> | 14 <script> |
| 15 if (window.testRunner) { | 15 if (window.testRunner) { |
| 16 window.testRunner.dumpAsText(); | 16 window.testRunner.dumpAsText(); |
| 17 window.testRunner.waitUntilDone(); | 17 window.testRunner.waitUntilDone(); |
| 18 } | 18 } |
| 19 | 19 |
| 20 var myFrames = subframe.frames; | 20 var myFrames = subframe.frames; |
| 21 | 21 |
| 22 function done() { | 22 function done() { |
| 23 var foo = myFrames.length; | 23 var foo = myFrames.length; |
| 24 document.getElementById("status").innerText = "SUCCESS"; | 24 document.getElementById("status").innerText = "SUCCESS"; |
| 25 if (window.testRunner) | 25 if (window.testRunner) |
| 26 window.testRunner.notifyDone(); | 26 window.testRunner.notifyDone(); |
| 27 } | 27 } |
| 28 | 28 |
| 29 subframe.document.location = "resources/notify-parent-done.html"; | 29 subframe.document.location = "resources/notify-parent-done.html"; |
| 30 </script> | 30 </script> |
| 31 </body> | 31 </body> |
| 32 </html> | 32 </html> |
| OLD | NEW |