Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(190)

Side by Side Diff: third_party/WebKit/LayoutTests/editing/execCommand/remove-list-1.html

Issue 2276563003: Convert editing/execCommand/remove-list-item-1.html to use w3c test harness (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 2016-08-25T10:29:13 Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/execCommand/remove-list-1-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!doctype html>
2 <script src="../../resources/testharness.js"></script>
3 <script src="../../resources/testharnessreport.js"></script>
4 <script src="../assert_selection.js"></script>
1 <script> 5 <script>
2 if (window.testRunner) { 6 test(() => assert_selection(
3 testRunner.dumpEditingCallbacks(); 7 [
4 testRunner.dumpAsText(); 8 '<div contenteditable>',
5 } 9 '<ol>',
10 '<li>|</li>',
11 '<li>foo bar</li>',
12 '</ol>',
13 '</div>',
14 ].join(''),
15 selection => {
16 selection.document.execCommand('selectAll');
17 selection.document.execCommand('insertOrderedList');
18 },
19 [
20 '<div contenteditable>',
21 // TODO(yosin): We should study why unlistify sets caret before
22 // last character.
23 '^<br>foo ba|r',
24 '</div>',
25 ].join('')),
26 'Unlistify with an empty list item');
6 </script> 27 </script>
7 <p>This tests de-listing content.</p>
8 <div id="div" contenteditable="true"><ol><li></li><li>There should be a single B R above this line and no OL or LI.</li></ol></div>
9 <p id="console"></p>
10
11 <script>
12
13 function log(message) {
14 var console = document.getElementById("console");
15 var text = document.createTextNode(message);
16 console.appendChild(text);
17 }
18
19 var div = document.getElementById("div");
20 var sel = window.getSelection();
21
22 div.focus();
23 document.execCommand("SelectAll");
24 document.execCommand("InsertOrderedList");
25
26 log(div.innerHTML);
27
28 </script>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/execCommand/remove-list-1-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698