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

Unified Diff: third_party/WebKit/LayoutTests/editing/selection/extend-by-word-002.html

Issue 2541163003: Fix TextIterator's behavior with first-letter (Closed)
Patch Set: Change relevant bug number Created 4 years 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
Index: third_party/WebKit/LayoutTests/editing/selection/extend-by-word-002.html
diff --git a/third_party/WebKit/LayoutTests/editing/selection/extend-by-word-002.html b/third_party/WebKit/LayoutTests/editing/selection/extend-by-word-002.html
index 8dae6a97d82a9c5ba66b31e3163690835e8584d0..6c5418a74739f90603282474f5981b6336110e82 100644
--- a/third_party/WebKit/LayoutTests/editing/selection/extend-by-word-002.html
+++ b/third_party/WebKit/LayoutTests/editing/selection/extend-by-word-002.html
@@ -55,7 +55,7 @@ function $(id) { return document.getElementById(id); }
if (window.internals)
yosin_UTC9 2016/12/01 09:41:42 Could you convert this test to assert_selection()
internals.settings.setEditingBehavior('mac');
var range = document.createRange();
-range.setStart($("test").querySelectorAll("li")[0], 0);
+range.setStart($("test").querySelectorAll("li")[0], 0); // |Appetizers
var selection = window.getSelection();
selection.removeAllRanges();
selection.addRange(range);
@@ -65,7 +65,9 @@ shouldBeEqualToString('selection.type', 'Range');
shouldBe('selection.anchorNode', '$("test").querySelectorAll("li")[0].childNodes[0]');
shouldBe('selection.anchorOffset', '0');
shouldBe('selection.focusNode', '$("test").querySelectorAll("li a")[3].firstChild');
-shouldBe('selection.focusOffset', '4');
+shouldBe('selection.focusOffset', '5'); // Steak| & Ribs.
+// Note that Blink currently renders the focus at a wrong position (Steak |&)
+// which is a known issue. See crbug.com/406218.
if (window.testRunner)
$('container').outerHTML = '';
</script>

Powered by Google App Engine
This is Rietveld 408576698