Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / editing / spelling / spellcheck-async-remove-frame.html
blob5187ed5e99373b57cc3e5a858324435c31c85127
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <script>
5 if (window.testRunner) {
6 testRunner.waitUntilDone();
7 testRunner.dumpAsText();
8 internals.settings.setAsynchronousSpellCheckingEnabled(true);
9 internals.settings.setUnifiedTextCheckerEnabled(true);
12 function runTest() {
13 var textToSelect = "This text should be selected, but this frame shouldn't be focused.";
14 var frame = document.getElementById("frame");
15 var s = frame.contentDocument.getSelection();
16 s.collapse(frame.contentDocument.body, 0);
17 frame.contentDocument.execCommand("InsertText", false, textToSelect);
18 frame.parentNode.removeChild(frame);
19 window.setTimeout(function() {
20 if (window.testRunner)
21 testRunner.notifyDone();
22 }, 50);
24 </script>
25 </head>
26 <body>
27 <div>PASS unless crash.</div>
28 <iframe id="frame" src="../resources/contenteditable-iframe-src.html" onload="runTest();"></iframe>
29 </body>
30 </html>