| OLD | NEW |
| 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> | 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../../fast/js/resources/js-test-pre.js"></script> | 4 <script src="../../fast/js/resources/js-test-pre.js"></script> |
| 5 <script src="resources/js-test-selection-shared.js"></script> | 5 <script src="resources/js-test-selection-shared.js"></script> |
| 6 </head> | 6 </head> |
| 7 <body> | 7 <body> |
| 8 <p id="description"></p> | 8 <p id="description"></p> |
| 9 <div id="console"></div> | 9 <div id="console"></div> |
| 10 <script> | 10 <script> |
| 11 description('Grammar checking for pasted text.'); | 11 description('Grammar checking for pasted text.'); |
| 12 | 12 |
| 13 testRunner.waitUntilDone(); | 13 jsTestIsAsync = true; |
| 14 | 14 |
| 15 var testRoot = document.createElement("div"); | 15 var testRoot = document.createElement("div"); |
| 16 document.body.insertBefore(testRoot, document.body.firstChild); | 16 document.body.insertBefore(testRoot, document.body.firstChild); |
| 17 | 17 |
| 18 var testTextArea = document.createElement("textarea"); | 18 var testTextArea = document.createElement("textarea"); |
| 19 testRoot.appendChild(testTextArea); | 19 testRoot.appendChild(testTextArea); |
| 20 | 20 |
| 21 var testInput = document.createElement("input"); | 21 var testInput = document.createElement("input"); |
| 22 testInput.setAttribute("type", "text"); | 22 testInput.setAttribute("type", "text"); |
| 23 testRoot.appendChild(testInput); | 23 testRoot.appendChild(testInput); |
| (...skipping 17 matching lines...) Expand all Loading... |
| 41 var sel = window.getSelection(); | 41 var sel = window.getSelection(); |
| 42 | 42 |
| 43 var tests = []; | 43 var tests = []; |
| 44 | 44 |
| 45 function done() | 45 function done() |
| 46 { | 46 { |
| 47 var next = tests.shift(); | 47 var next = tests.shift(); |
| 48 if (next) | 48 if (next) |
| 49 return window.setTimeout(next, 0); | 49 return window.setTimeout(next, 0); |
| 50 testRoot.style.display = "none"; | 50 testRoot.style.display = "none"; |
| 51 testRunner.notifyDone(); | 51 finishJSTest(); |
| 52 } | 52 } |
| 53 | 53 |
| 54 function findFirstTextNode(node) | 54 function findFirstTextNode(node) |
| 55 { | 55 { |
| 56 function iterToFindFirstTextNode(node) | 56 function iterToFindFirstTextNode(node) |
| 57 { | 57 { |
| 58 if (node instanceof Text) | 58 if (node instanceof Text) |
| 59 return node; | 59 return node; |
| 60 | 60 |
| 61 var childNodes = node.childNodes; | 61 var childNodes = node.childNodes; |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 tests.push(function() { pasteAndVerify(testSourceDecorated, testTextArea, ["an"]
); }); | 149 tests.push(function() { pasteAndVerify(testSourceDecorated, testTextArea, ["an"]
); }); |
| 150 tests.push(function() { pasteAndVerify(testSourceMulti, testTextArea, ["an", "an
"]); }); | 150 tests.push(function() { pasteAndVerify(testSourceMulti, testTextArea, ["an", "an
"]); }); |
| 151 | 151 |
| 152 done(); | 152 done(); |
| 153 | 153 |
| 154 var successfullyParsed = true; | 154 var successfullyParsed = true; |
| 155 </script> | 155 </script> |
| 156 <script src="../../fast/js/resources/js-test-post.js"></script> | 156 <script src="../../fast/js/resources/js-test-post.js"></script> |
| 157 </body> | 157 </body> |
| 158 </html> | 158 </html> |
| OLD | NEW |