| Index: third_party/WebKit/LayoutTests/editing/selection/collapse/collapse_before_select.html
|
| diff --git a/third_party/WebKit/LayoutTests/editing/selection/collapse/collapse_before_select.html b/third_party/WebKit/LayoutTests/editing/selection/collapse/collapse_before_select.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..b21119f411f1e6fa1529d8e20816fd9dda0682b0
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/editing/selection/collapse/collapse_before_select.html
|
| @@ -0,0 +1,18 @@
|
| +<!doctype html>
|
| +<script src="../../../resources/testharness.js"></script>
|
| +<script src="../../../resources/testharnessreport.js"></script>
|
| +<div contenteditable id="anchor"><select><option>One</option></select>blaa</div>
|
| +<div id="log"></div>
|
| +<script>
|
| +test(function() {
|
| + var selection = window.getSelection();
|
| + var select = document.querySelector('select');
|
| + selection.collapse(select, 0);
|
| +
|
| + var anchor = document.getElementById('anchor');
|
| + assert_equals(selection.anchorNode, anchor, 'anchorNode');
|
| + assert_equals(selection.anchorOffset, 0, 'anchorOffset');
|
| + assert_equals(selection.focusNode, anchor, 'focusNode');
|
| + assert_equals(selection.focusOffset, 0, 'focusOffset');
|
| +}, 'can not place caret inside SELECT element');
|
| +</script>
|
|
|