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

Unified Diff: third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.html

Issue 2445323005: Allow spellcheck_test to run custom callback at completion (Closed)
Patch Set: Wed Oct 26 16:59:50 JST 2016 Created 4 years, 2 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.html
diff --git a/third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.html b/third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.html
index 23b5cd8fc475815f40b600fec17ecf73e639e5ff..033a821407301e1e473f434b882310abeebc541a 100644
--- a/third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.html
+++ b/third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.html
@@ -44,5 +44,24 @@ spellcheck_test(
'<input type="text" value="_asd_.">',
'Mark misspellings in <input>.');
+spellcheck_test(
+ '<div contenteditable spellcheck="false">zz.|</div>',
+ '',
+ '<div contenteditable spellcheck="false">zz.</div>',
+ {
+ title: 'No marker on misspelled word when spellcheck=false.',
+ callback: sample => spellcheck_test(
+ sample,
+ document => {
+ const div = document.querySelector('div');
+ div.setAttribute('spellcheck', 'true');
+ // Trigger spellchecker by selection change.
+ document.getSelection().collapse(div, 0);
+ },
+ '<div contenteditable spellcheck="true">_zz_.</div>',
+ 'Marker appears after setting spellcheck=true.'
+ )
+ });
+
// TODO(xiaochengh): Design interface for checking marker description.
</script>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/spelling/spellcheck_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698