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

Side by Side Diff: third_party/WebKit/LayoutTests/editing/inserting/insert-div-022.html

Issue 2178863002: Convert editing/insert-div-22.html to use w3c test harness (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 2016-07-25T17:34:19 Created 4 years, 5 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/platform/linux/editing/inserting/insert-div-022-expected.png » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <html> 1 <!doctype html>
2 <head> 2 <script src="../../resources/testharness.js"></script>
3 3 <script src="../../resources/testharnessreport.js"></script>
4 <style> 4 <script src="../assert_selection.js"></script>
5 body {
6 font-size: 24px;
7 }
8 .editing {
9 border: 2px solid red;
10 padding: 12px;
11 }
12 p {
13 border: 2px solid blue;
14 padding: 12px;
15 }
16 br {
17 background-color: green;
18 }
19
20 </style>
21 <script src=../editing.js language="JavaScript" type="text/JavaScript" ></script >
22
23 <script> 5 <script>
24 6 test(() => assert_selection(
25 function editingTest() { 7 [
26 for (i = 0; i < 3; i++) 8 '<div contenteditable>',
27 moveSelectionForwardByCharacterCommand(); 9 '<p id="test"><b>foo|</b><br>bar</p>',
28 insertParagraphCommand(); 10 '</div>',
29 typeCharacterCommand(); 11 ].join(''),
30 } 12 selection => {
31 13 selection.document.execCommand('insertParagraph');
14 selection.document.execCommand('insertText', false, 'x');
15 },
16 [
17 '<div contenteditable>',
18 '<p id="test"><b>foo</b></p>',
19 '<p id="test"><b>x|<br></b>bar</p>',
20 '</div>',
21 ].join('')),
22 'Insert "x" before BR, since insertParagraph puts caret before BR');
32 </script> 23 </script>
33
34 <title>Editing Test</title>
35 </head>
36 <body contenteditable id="root" style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space;">
37
38 Test inserting paragraphs: should see "foo" in a blue box, then a blue box with with two lines in it: First line a bold "x"; second line a non-bold "bar". Fix f or this bug:
39 <a href="rdar://problem/3924579">&lt;rdar://problem/3927554&gt;</a> Style info a pplied to remainder of document after a newline is entered
40
41 <div style="height: 12px"></div>
42
43 <p id="test"><b>foo</b><br>bar</p>
44
45 <script>
46 runEditingTest();
47 </script>
48
49 </body>
50 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/platform/linux/editing/inserting/insert-div-022-expected.png » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698