| Index: third_party/WebKit/LayoutTests/editing/selection/modify_extend/extend-by-character-002.html
|
| diff --git a/third_party/WebKit/LayoutTests/editing/selection/modify_extend/extend-by-character-002.html b/third_party/WebKit/LayoutTests/editing/selection/modify_extend/extend-by-character-002.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..65a4596755c51f23a819b56a27962ff47abf488c
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/editing/selection/modify_extend/extend-by-character-002.html
|
| @@ -0,0 +1,28 @@
|
| +<!DOCTYPE html>
|
| +<script src="../../../resources/testharness.js"></script>
|
| +<script src="../../../resources/testharnessreport.js"></script>
|
| +<body>
|
| +<div contenteditable id="root" class="editing">
|
| +<span id="span">a<img src="../../resources/abe.png">new
|
| +<br>nation <i> </i> <img src="../../resources/abe.png">
|
| +
|
| +
|
| +conceived
|
| +<br>nation<img src="../../resources/abe.png"></span>
|
| +</div>
|
| +<div id="log"></div>
|
| +<script>
|
| +test(function () {
|
| + var selection = getSelection();
|
| + selection.collapse(span.firstChild, 0);
|
| + for (i = 0; i < 33; i++) {
|
| + selection.modify("extend", "forward", "character");
|
| + }
|
| + assert_equals(selection.anchorNode, span.firstChild);
|
| + assert_equals(selection.anchorOffset, 0);
|
| + assert_equals(selection.focusNode, span.childNodes[10]); // "nation" text
|
| + assert_equals(selection.focusOffset, 6);
|
| +});
|
| +</script>
|
| +
|
| +</body>
|
|
|