editing/pasteboard/5247341.html should be a dump-as-markup test
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Mar 2013 19:49:45 +0000 (19:49 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Mar 2013 19:49:45 +0000 (19:49 +0000)
https://bugs.webkit.org/show_bug.cgi?id=111397

Reviewed by Darin Adler.

Convert the test to use dump-as-markup.js. Also rename it to preserve-line-break-at-end-of-pasted-content
to reflect the content of the test.

* editing/pasteboard/5247341.html: Removed.
* editing/pasteboard/preserve-line-break-at-end-of-pasted-content-expected.txt: Added.
* editing/pasteboard/preserve-line-break-at-end-of-pasted-content.html: Copied from LayoutTests/editing/pasteboard/5247341.html.
* platform/chromium-linux/editing/pasteboard/5247341-expected.png: Removed.
* platform/chromium-mac-lion/editing/pasteboard/5247341-expected.png: Removed.
* platform/chromium-mac-snowleopard/editing/pasteboard/5247341-expected.png: Removed.
* platform/chromium-mac/editing/pasteboard/5247341-expected.png: Removed.
* platform/chromium-win/editing/pasteboard/5247341-expected.png: Removed.
* platform/chromium-win/editing/pasteboard/5247341-expected.txt: Removed.
* platform/chromium/editing/pasteboard/5247341-expected.txt: Removed.
* platform/gtk/editing/pasteboard/5247341-expected.png: Removed.
* platform/gtk/editing/pasteboard/5247341-expected.txt: Removed.
* platform/mac/editing/pasteboard/5247341-expected.png: Removed.
* platform/mac/editing/pasteboard/5247341-expected.txt: Removed.
* platform/qt/editing/pasteboard/5247341-expected.png: Removed.
* platform/qt/editing/pasteboard/5247341-expected.txt: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@144793 268f45cc-cd09-0410-ab3c-d52691b4dbfc

17 files changed:
LayoutTests/ChangeLog
LayoutTests/editing/pasteboard/5247341.html [deleted file]
LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-expected.txt [new file with mode: 0644]
LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content.html [new file with mode: 0644]
LayoutTests/platform/chromium-linux/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/chromium-mac-lion/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/chromium-mac-snowleopard/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/chromium-mac/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.txt [deleted file]
LayoutTests/platform/chromium/editing/pasteboard/5247341-expected.txt [deleted file]
LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.txt [deleted file]
LayoutTests/platform/mac/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/mac/editing/pasteboard/5247341-expected.txt [deleted file]
LayoutTests/platform/qt/editing/pasteboard/5247341-expected.png [deleted file]
LayoutTests/platform/qt/editing/pasteboard/5247341-expected.txt [deleted file]

index d98685d..42e5647 100644 (file)
@@ -1,3 +1,30 @@
+2013-03-04  Ryosuke Niwa  <rniwa@webkit.org>
+
+        editing/pasteboard/5247341.html should be a dump-as-markup test
+        https://bugs.webkit.org/show_bug.cgi?id=111397
+
+        Reviewed by Darin Adler.
+
+        Convert the test to use dump-as-markup.js. Also rename it to preserve-line-break-at-end-of-pasted-content
+        to reflect the content of the test.
+
+        * editing/pasteboard/5247341.html: Removed.
+        * editing/pasteboard/preserve-line-break-at-end-of-pasted-content-expected.txt: Added.
+        * editing/pasteboard/preserve-line-break-at-end-of-pasted-content.html: Copied from LayoutTests/editing/pasteboard/5247341.html.
+        * platform/chromium-linux/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/chromium-mac-lion/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/chromium-mac-snowleopard/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/chromium-mac/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/chromium-win/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/chromium-win/editing/pasteboard/5247341-expected.txt: Removed.
+        * platform/chromium/editing/pasteboard/5247341-expected.txt: Removed.
+        * platform/gtk/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/gtk/editing/pasteboard/5247341-expected.txt: Removed.
+        * platform/mac/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/mac/editing/pasteboard/5247341-expected.txt: Removed.
+        * platform/qt/editing/pasteboard/5247341-expected.png: Removed.
+        * platform/qt/editing/pasteboard/5247341-expected.txt: Removed.
+
 2013-03-05  Tony Chang  <tony@chromium.org>
 
         Fix some crashes in render sliders
diff --git a/LayoutTests/editing/pasteboard/5247341.html b/LayoutTests/editing/pasteboard/5247341.html
deleted file mode 100644 (file)
index eaa81f7..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-<p>This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragaphs containing "Hello World!" and an empty third paragraph with the caret in it.</p>
-<div id="root" contenteditable="true">Hello World!<div id="div"><br></div></div>
-
-<script>
-root = document.getElementById("root");
-root.focus();
-document.execCommand("SelectAll");
-document.execCommand("Copy");
-
-selection = window.getSelection();
-div = document.getElementById("div");
-selection.setPosition(div, 0);
-document.execCommand("Paste");
-</script>
diff --git a/LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-expected.txt b/LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content-expected.txt
new file mode 100644 (file)
index 0000000..7f6da34
--- /dev/null
@@ -0,0 +1,18 @@
+This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragraphs containing "Hello World!" and an empty third paragraph with the caret in it.
+
+Before copy and paste:
+| "<#selection-anchor>Hello World!"
+| <div>
+|   id="div"
+|   <#selection-focus>
+|   <br>
+
+After copy and paste:
+| "Hello World!"
+| <div>
+|   id="div"
+|   "Hello World!"
+|   <br>
+| <div>
+|   <#selection-caret>
+|   <br>
diff --git a/LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content.html b/LayoutTests/editing/pasteboard/preserve-line-break-at-end-of-pasted-content.html
new file mode 100644 (file)
index 0000000..d650184
--- /dev/null
@@ -0,0 +1,26 @@
+<!DOCTYPE html>
+<html>
+<body>
+<p id="description">This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragraphs containing "Hello World!" and an empty third paragraph with the caret in it.</p>
+<div id="root" contenteditable="true">Hello World!<div id="div"><br></div></div>
+<script src="../../resources/dump-as-markup.js"></script>
+<script>
+
+Markup.description(document.getElementById('description').textContent);
+
+root = document.getElementById("root");
+root.focus();
+document.execCommand("SelectAll");
+document.execCommand("Copy");
+
+Markup.dump(root, 'Before copy and paste');
+
+selection = window.getSelection();
+div = document.getElementById("div");
+selection.setPosition(div, 0);
+document.execCommand("Paste");
+
+Markup.dump(root, 'After copy and paste');
+</script>
+</body>
+</html>
diff --git a/LayoutTests/platform/chromium-linux/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/chromium-linux/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index 8e36bb4..0000000
Binary files a/LayoutTests/platform/chromium-linux/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/chromium-mac-lion/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/chromium-mac-lion/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index a51c320..0000000
Binary files a/LayoutTests/platform/chromium-mac-lion/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/chromium-mac-snowleopard/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/chromium-mac-snowleopard/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index d51717b..0000000
Binary files a/LayoutTests/platform/chromium-mac-snowleopard/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/chromium-mac/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/chromium-mac/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index 8489fee..0000000
Binary files a/LayoutTests/platform/chromium-mac/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index 2511868..0000000
Binary files a/LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.txt b/LayoutTests/platform/chromium-win/editing/pasteboard/5247341-expected.txt
deleted file mode 100644 (file)
index e5ebbf3..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-layer at (0,0) size 800x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,8) size 784x584
-      RenderBlock {P} at (0,0) size 784x40
-        RenderText {#text} at (0,0) size 765x39
-          text run at (0,0) width 765: "This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragaphs containing"
-          text run at (0,20) width 385: "\"Hello World!\" and an empty third paragraph with the caret in it."
-      RenderBlock {DIV} at (0,56) size 784x60
-        RenderBlock (anonymous) at (0,0) size 784x20
-          RenderText {#text} at (0,0) size 80x19
-            text run at (0,0) width 80: "Hello World!"
-        RenderBlock {DIV} at (0,20) size 784x20
-          RenderText {#text} at (0,0) size 80x19
-            text run at (0,0) width 80: "Hello World!"
-        RenderBlock {DIV} at (0,40) size 784x20
-          RenderBR {BR} at (0,0) size 0x19
-caret: position 0 of child 0 {BR} of child 2 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/chromium/editing/pasteboard/5247341-expected.txt b/LayoutTests/platform/chromium/editing/pasteboard/5247341-expected.txt
deleted file mode 100644 (file)
index bde73d8..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-layer at (0,0) size 800x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,8) size 784x584
-      RenderBlock {P} at (0,0) size 784x36
-        RenderText {#text} at (0,0) size 735x36
-          text run at (0,0) width 735: "This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragaphs"
-          text run at (0,18) width 478: "containing \"Hello World!\" and an empty third paragraph with the caret in it."
-      RenderBlock {DIV} at (0,52) size 784x54
-        RenderBlock (anonymous) at (0,0) size 784x18
-          RenderText {#text} at (0,0) size 84x18
-            text run at (0,0) width 84: "Hello World!"
-        RenderBlock {DIV} at (0,18) size 784x18
-          RenderText {#text} at (0,0) size 84x18
-            text run at (0,0) width 84: "Hello World!"
-        RenderBlock {DIV} at (0,36) size 784x18
-          RenderBR {BR} at (0,0) size 0x18
-caret: position 0 of child 0 {BR} of child 2 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index 6cf2a92..0000000
Binary files a/LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.txt b/LayoutTests/platform/gtk/editing/pasteboard/5247341-expected.txt
deleted file mode 100644 (file)
index af57d8a..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-layer at (0,0) size 800x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,8) size 784x584
-      RenderBlock {P} at (0,0) size 784x36
-        RenderText {#text} at (0,0) size 735x37
-          text run at (0,0) width 735: "This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragaphs"
-          text run at (0,18) width 478: "containing \"Hello World!\" and an empty third paragraph with the caret in it."
-      RenderBlock {DIV} at (0,52) size 784x54
-        RenderBlock (anonymous) at (0,0) size 784x18
-          RenderText {#text} at (0,0) size 84x19
-            text run at (0,0) width 84: "Hello World!"
-        RenderBlock {DIV} at (0,18) size 784x18
-          RenderText {#text} at (0,0) size 84x19
-            text run at (0,0) width 84: "Hello World!"
-        RenderBlock {DIV} at (0,36) size 784x18
-          RenderBR {BR} at (0,0) size 0x19
-caret: position 0 of child 0 {BR} of child 2 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/mac/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/mac/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index 224fbe2..0000000
Binary files a/LayoutTests/platform/mac/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/mac/editing/pasteboard/5247341-expected.txt b/LayoutTests/platform/mac/editing/pasteboard/5247341-expected.txt
deleted file mode 100644 (file)
index bde73d8..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-layer at (0,0) size 800x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,8) size 784x584
-      RenderBlock {P} at (0,0) size 784x36
-        RenderText {#text} at (0,0) size 735x36
-          text run at (0,0) width 735: "This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragaphs"
-          text run at (0,18) width 478: "containing \"Hello World!\" and an empty third paragraph with the caret in it."
-      RenderBlock {DIV} at (0,52) size 784x54
-        RenderBlock (anonymous) at (0,0) size 784x18
-          RenderText {#text} at (0,0) size 84x18
-            text run at (0,0) width 84: "Hello World!"
-        RenderBlock {DIV} at (0,18) size 784x18
-          RenderText {#text} at (0,0) size 84x18
-            text run at (0,0) width 84: "Hello World!"
-        RenderBlock {DIV} at (0,36) size 784x18
-          RenderBR {BR} at (0,0) size 0x18
-caret: position 0 of child 0 {BR} of child 2 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/pasteboard/5247341-expected.png b/LayoutTests/platform/qt/editing/pasteboard/5247341-expected.png
deleted file mode 100644 (file)
index 7df3947..0000000
Binary files a/LayoutTests/platform/qt/editing/pasteboard/5247341-expected.png and /dev/null differ
diff --git a/LayoutTests/platform/qt/editing/pasteboard/5247341-expected.txt b/LayoutTests/platform/qt/editing/pasteboard/5247341-expected.txt
deleted file mode 100644 (file)
index 373cd17..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-layer at (0,0) size 800x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,8) size 784x584
-      RenderBlock {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 765x38
-          text run at (0,0) width 765: "This tests for a bug where newlines would not be preserved during copy/paste. Below you should see two paragaphs containing"
-          text run at (0,19) width 385: "\"Hello World!\" and an empty third paragraph with the caret in it."
-      RenderBlock {DIV} at (0,54) size 784x57
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 80x19
-            text run at (0,0) width 80: "Hello World!"
-        RenderBlock {DIV} at (0,19) size 784x19
-          RenderText {#text} at (0,0) size 80x19
-            text run at (0,0) width 80: "Hello World!"
-        RenderBlock {DIV} at (0,38) size 784x19
-          RenderBR {BR} at (0,0) size 0x19
-caret: position 0 of child 0 {BR} of child 2 {DIV} of child 2 {DIV} of body