Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/editing/inserting/merge_after_delete.html |
| diff --git a/third_party/WebKit/LayoutTests/editing/inserting/merge_after_delete.html b/third_party/WebKit/LayoutTests/editing/inserting/merge_after_delete.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..1969b6b1759b88b8d9ce491c8edab37624cb4829 |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/editing/inserting/merge_after_delete.html |
| @@ -0,0 +1,43 @@ |
| +<!doctype html> |
| +<script src="../../resources/testharness.js"></script> |
| +<script src="../../resources/testharnessreport.js"></script> |
| +<script src="../assert_selection.js"></script> |
| +<script> |
| +test(() => assert_selection( |
| + '<div contenteditable><div>f^oo</div>bar|<br></div>', |
| + 'insertHTML <div>foo</div><br class="Apple-interchange-newline">', |
| + '<div contenteditable><div>ffoo</div><div>|<br></div></div>'), |
| + 'BR interchange-newline is not inserted'); |
| + |
| +test(() => assert_selection( |
| + [ |
| + '<div contenteditable>', |
| + '<div style="color:red">b^ar</div>', |
| + '<div style="color:blue">baz|</div>', |
|
Xiaocheng
2016/07/26 09:43:35
<br> is missing.
yosin_UTC9
2016/07/27 01:45:36
Good catch!
Done.
|
| + '</div>', |
| + ].join(''), |
| + 'insertHTML <div>FOO</div><div>BAR</div>', |
| + [ |
| + '<div contenteditable>', |
| + '<div style="color:red">bFOO</div>', |
| + '<div>BAR|</div>', |
| + '</div>', |
| + ].join('')), |
| + 'Use existing DIV at replace when partial replacement'); |
| + |
| +test(() => assert_selection( |
| + [ |
| + '<div contenteditable>', |
| + '<div style="color:red">b^ar</div>', |
| + 'baz|<br>', |
| + '</div>', |
| + ].join(''), |
| + 'insertHTML <div>FOO</div><div>BAR</div>', |
| + [ |
| + '<div contenteditable>', |
| + '<div style="color:red">bFOO</div>', |
| + '<div>BAR|</div>', |
| + '</div>', |
| + ].join('')), |
| + 'Replace text+BR to DIV'); |
| +</script> |