Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(362)

Side by Side Diff: third_party/WebKit/LayoutTests/editing/spelling/copy-paste-crash.html

Issue 2486693002: Convert editing/spelling/copy-paste-crash.html with spellcheck_test (Closed)
Patch Set: Convert copy-paste-crash.html Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/spelling/copy-paste-crash-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <script src="../../resources/testharness.js"></script>
3 <head> 3 <script src="../../resources/testharnessreport.js"></script>
4 <script src="../../resources/js-test.js"></script> 4 <script src="../assert_selection.js"></script>
5 <script src="resources/util.js"></script> 5 <script src="spellcheck_test.js"></script>
6 </head>
7 <body>
8 <div id="container">
9 <input id="destination" type="text" name="type" value="">
10 </div>
11 6
12 <script> 7 <script>
13 8 spellcheck_test(
14 description("Spell check does not crash after Ctrl-X/Ctrl-V/type text in ASAN. " + 9 '<input type="text">',
15 "To test manually, type 'A', Ctrl-A, Ctrl-X, Ctrl-V, and start typin g again. " + 10 document => {
16 "The test succeeds when there's no crash in the last step."); 11 document.querySelector('input').focus();
17 12 document.execCommand('insertText', false, 'A');
18 initSpellTest("destination", "A", function(textNode) { 13 },
19 var behaviors = ["win", "mac"]; 14 '<input type="text" value="A">',
20 for (var i = 0; i < behaviors.length; i++) { 15 {
21 internals.settings.setEditingBehavior(behaviors[i]); 16 title: 'Initial setup.',
22 document.execCommand("SelectAll"); 17 callback: sample => spellcheck_test(
23 document.execCommand("Cut"); 18 sample,
24 document.execCommand("Paste"); 19 document => {
25 document.execCommand("InsertText", false, "A"); 20 document.execCommand('selectAll');
26 } 21 document.execCommand('cut');
27 log("PASS Did not crash"); 22 document.execCommand('paste');
28 }); 23 document.execCommand('insertText', false, 'A');
29 24 },
25 '<input type="text" value="AA">',
26 'Spell check does not crash after Ctrl-X/Ctrl-V/type text in ASAN.')
27 });
30 </script> 28 </script>
31 </body>
32 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/spelling/copy-paste-crash-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698