OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <link rel="stylesheet" href="../../fast/js/resources/js-test-style.css"> | 4 <link rel="stylesheet" href="../../fast/js/resources/js-test-style.css"> |
5 <script src="../../fast/js/resources/js-test-pre.js"></script> | 5 <script src="../../fast/js/resources/js-test-pre.js"></script> |
6 <script src="../editing.js"></script> | 6 <script src="../editing.js"></script> |
7 <style> | 7 <style> |
8 .editing { | 8 .editing { |
9 border: 2px solid red; | 9 border: 2px solid red; |
10 padding: 6px; | 10 padding: 6px; |
11 font-size: 18px; | 11 font-size: 18px; |
12 } | 12 } |
13 </style> | 13 </style> |
14 </head> | 14 </head> |
15 <body> | 15 <body> |
16 <pre id="description"></pre> | 16 <pre id="description"></pre> |
17 <pre id="console"></pre> | 17 <pre id="console"></pre> |
18 <div id="container"></div> | 18 <div id="container"></div> |
19 | 19 |
20 <script> | 20 <script> |
21 description("Test for Unified Spell Checker & Async Spell Checker."); | 21 description("Test for Unified Spell Checker & Async Spell Checker."); |
22 | 22 |
23 if (window.testRunner) { | 23 jsTestIsAsync = true; |
| 24 |
| 25 if (window.testRunner) |
24 testRunner.dumpAsText(); | 26 testRunner.dumpAsText(); |
25 testRunner.waitUntilDone(); | |
26 } | |
27 | 27 |
28 if (window.internals) { | 28 if (window.internals) { |
29 internals.settings.setAsynchronousSpellCheckingEnabled(true); | 29 internals.settings.setAsynchronousSpellCheckingEnabled(true); |
30 internals.settings.setUnifiedTextCheckerEnabled(true); | 30 internals.settings.setUnifiedTextCheckerEnabled(true); |
31 } | 31 } |
32 | 32 |
33 var container = document.getElementById('container'); | 33 var container = document.getElementById('container'); |
34 function removeChildren(node) { | 34 function removeChildren(node) { |
35 while (node.firstChild) | 35 while (node.firstChild) |
36 node.removeChild(node.firstChild); | 36 node.removeChild(node.firstChild); |
(...skipping 13 matching lines...) Expand all Loading... |
50 ]; | 50 ]; |
51 | 51 |
52 var testNo = 0; | 52 var testNo = 0; |
53 function doTestIfAny() { | 53 function doTestIfAny() { |
54 var next = testData.shift(); | 54 var next = testData.shift(); |
55 if (next) | 55 if (next) |
56 return window.setTimeout(function(){ doTest(++testNo, next.text, next.ma
rked); }, 0); | 56 return window.setTimeout(function(){ doTest(++testNo, next.text, next.ma
rked); }, 0); |
57 | 57 |
58 // No more tests. | 58 // No more tests. |
59 removeChildren(container); | 59 removeChildren(container); |
60 if (window.testRunner) | 60 finishJSTest(); |
61 testRunner.notifyDone(); | |
62 } | 61 } |
63 | 62 |
64 function createEditableElement(id) { | 63 function createEditableElement(id) { |
65 var e = document.createElement('div'); | 64 var e = document.createElement('div'); |
66 e.setAttribute("contentEditable", "true"); | 65 e.setAttribute("contentEditable", "true"); |
67 e.className = 'editing'; | 66 e.className = 'editing'; |
68 e.id = id; | 67 e.id = id; |
69 | 68 |
70 return e; | 69 return e; |
71 } | 70 } |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 } | 122 } |
124 } | 123 } |
125 | 124 |
126 doTestIfAny(); | 125 doTestIfAny(); |
127 | 126 |
128 var successfullyParsed = true; | 127 var successfullyParsed = true; |
129 </script> | 128 </script> |
130 <script src="../../fast/js/resources/js-test-post.js"></script> | 129 <script src="../../fast/js/resources/js-test-post.js"></script> |
131 </body> | 130 </body> |
132 </html> | 131 </html> |
OLD | NEW |