Use testRunner instead of layoutTestController in fast/doctypes, dom, dynamic, encodi...
[WebKit-https.git] / LayoutTests / fast / dom / Range / range-selection-across-documents-crash.html
1 <!DOCTYPE html>\r
2 <html>\r
3 <head>\r
4 <script>\r
5 if (window.testRunner)\r
6     testRunner.dumpAsText();\r
7 \r
8 function runTest()\r
9 {\r
10     var iframeElement = document.getElementById('iframe1');\r
11     var iframeDocument = iframeElement.contentDocument;\r
12     var iframeDocumentRoot = iframeDocument.documentElement;\r
13 \r
14     var selection = window.getSelection();\r
15     var range = document.createRange();\r
16     selection.addRange(range);\r
17     range.selectNode(iframeDocumentRoot);\r
18     selection.addRange(range);\r
19     iframeDocument.removeChild(iframeDocumentRoot);\r
20 }\r
21 </script>\r
22 </head>\r
23 <body>\r
24 Test passes if it does not crash.\r
25 <iframe id="iframe1" onload="runTest()"></iframe>\r
26 </body>\r
27 </html>\r