Index: third_party/WebKit/LayoutTests/editing/inserting/multiple-lines-selected.html |
diff --git a/third_party/WebKit/LayoutTests/editing/inserting/multiple-lines-selected.html b/third_party/WebKit/LayoutTests/editing/inserting/multiple-lines-selected.html |
index 38574b5186059d69aceb161fe19b5f9a36879109..b225e02fc19e80df38b88a5174144980b2049543 100644 |
--- a/third_party/WebKit/LayoutTests/editing/inserting/multiple-lines-selected.html |
+++ b/third_party/WebKit/LayoutTests/editing/inserting/multiple-lines-selected.html |
@@ -1,18 +1,12 @@ |
+<!doctype html> |
+<script src="../../resources/testharness.js"></script> |
+<script src="../../resources/testharnessreport.js"></script> |
+<script src="../assert_selection.js"></script> |
+<div id="log"></div> |
<script> |
-if (window.testRunner) |
- testRunner.dumpEditingCallbacks(); |
-</script> |
-<p>This tests inserting a paragraph separator into a selection that spans multiple paragraphs. 'ar' should be on the line after 'f' and the caret should be just before the 'a'.</p> |
-<div id="test" contenteditable="true"><div>foo</div><div>bar</div></div> |
- |
-<script> |
-var s = window.getSelection(); |
-var e = document.getElementById("test"); |
- |
-s.collapse(e, 0); |
-s.modify("move", "forward", "character"); |
-s.modify("extend", "forward", "line"); |
- |
-document.execCommand("InsertParagraph"); |
- |
+test(() => assert_selection( |
+ '<div contenteditable><div>f^oo</div><div>b|ar</div></div>', |
+ 'insertParagraph', |
+ '<div contenteditable><div>f</div><div>|ar</div></div>'), |
+ 'Insert a paragraph separator into a selection that spans multiple paragraphs'); |
</script> |