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

Unified Diff: third_party/WebKit/LayoutTests/editing/pasteboard/copy_and_paste_with_colored_text.html

Issue 2342673003: Convert editing/pasteboard/5065605.html to use w3c test harness (Closed)
Patch Set: 2016-09-15T18:02:22 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/editing/pasteboard/5065605-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/editing/pasteboard/copy_and_paste_with_colored_text.html
diff --git a/third_party/WebKit/LayoutTests/editing/pasteboard/paste-table-003.html b/third_party/WebKit/LayoutTests/editing/pasteboard/copy_and_paste_with_colored_text.html
similarity index 55%
copy from third_party/WebKit/LayoutTests/editing/pasteboard/paste-table-003.html
copy to third_party/WebKit/LayoutTests/editing/pasteboard/copy_and_paste_with_colored_text.html
index aabf8999c7239b72381783ad94fa38bb07163d8f..6592a3ecef642446380cda00307e3f8474632a71 100644
--- a/third_party/WebKit/LayoutTests/editing/pasteboard/paste-table-003.html
+++ b/third_party/WebKit/LayoutTests/editing/pasteboard/copy_and_paste_with_colored_text.html
@@ -10,25 +10,26 @@ test(() => {
assert_selection(
[
'<div contenteditable>',
- '^<table><tbody><tr><td>one</td><td>two</td></tr></tbody></table>|',
- '<div id="target">replaceme</div>',
+ '<font color="red">^abc</font>',
+ '<div><font color="red">def|</font></div>',
'</div>',
].join(''),
selection => {
selection.document.execCommand('copy');
- const target = selection.document.getElementById('target');
- selection.collapse(target, 0);
- selection.extend(target, 1);
+ selection.modify('move', 'forward', 'character');
+ selection.document.execCommand('insertParagraph');
selection.document.execCommand('paste');
},
[
'<div contenteditable>',
- '<table><tbody><tr><td>one</td><td>two</td></tr></tbody></table>',
- '<div id="target">',
- '<table><tbody><tr><td>one</td><td>two<br>|<br></td></tr></tbody></table>',
+ '<font color="red">abc</font>',
+ '<div><font color="red">def</font></div>',
+ '<div>',
+ '<font color="red">abc</font>',
+ '<div><font color="red">def|</font></div>',
'</div>',
'</div>',
].join(''),
- 'Paste TABLE to replace text');
-}, 'Paste TABLE');
+ 'Copy and paste with colored text');
+});
</script>
« no previous file with comments | « third_party/WebKit/LayoutTests/editing/pasteboard/5065605-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698