Index: third_party/WebKit/LayoutTests/editing/selection/modify_move/move-by-character-003.html |
diff --git a/third_party/WebKit/LayoutTests/editing/selection/modify_move/move-by-character-003.html b/third_party/WebKit/LayoutTests/editing/selection/modify_move/move-by-character-003.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..e60a6c7f9fa9c200096bba91b118f3235e39ab11 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/editing/selection/modify_move/move-by-character-003.html |
@@ -0,0 +1,24 @@ |
+<!DOCTYPE html> |
+<script src="../../../resources/testharness.js"></script> |
+<script src="../../../resources/testharnessreport.js"></script> |
+<body> |
+<div contenteditable id="root" class="editing"> |
+<span id="sample"><i>F and seven</i> years <b> as </b>our fathers f upon this |
+continent, a new nation, conceived in Liberty, and dedicated to the |
+proposition that all |
+<br>men are created equal.</span> |
+</div> |
+<div id="log"></div> |
+<script> |
+test(function () { |
+ var selection = window.getSelection(); |
+ selection.collapse(sample, 0); |
+ for (i = 0; i < 159; ++i) |
+ selection.modify('move', 'forward', 'character'); |
+ assert_true(selection.isCollapsed, 'isCollapsed'); |
+ assert_equals(selection.anchorNode, sample.childNodes[5], 'anchorNode'); |
+ assert_equals(selection.anchorOffset, 21, 'anchorOffset'); |
+}); |
+</script> |
+ |
+</body> |