Reviewed by me
authorkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 14 Jun 2004 17:59:46 +0000 (17:59 +0000)
committerkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 14 Jun 2004 17:59:46 +0000 (17:59 +0000)
        Added a few more editing-related layout tests.

        * layout-tests/editing/inserting/insert-3654864-fix-expected.txt: Added.
        * layout-tests/editing/inserting/insert-3654864-fix.html: Added.
        * layout-tests/editing/inserting/insert-3659587-fix-expected.txt: Added.
        * layout-tests/editing/inserting/insert-3659587-fix.html: Added.
        * layout-tests/editing/inserting/insert-after-delete-001-expected.txt: Added.
        * layout-tests/editing/inserting/insert-after-delete-001.html: Added.
        * layout-tests/editing/inserting/insert-br-case1-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-case1.html: Added.
        * layout-tests/editing/inserting/insert-br-case2-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-case2.html: Added.
        * layout-tests/editing/inserting/insert-br-case3-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-case3.html: Added.

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

13 files changed:
LayoutTests/editing/inserting/insert-3654864-fix-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-3654864-fix.html [new file with mode: 0644]
LayoutTests/editing/inserting/insert-3659587-fix-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-3659587-fix.html [new file with mode: 0644]
LayoutTests/editing/inserting/insert-after-delete-001-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-after-delete-001.html [new file with mode: 0644]
LayoutTests/editing/inserting/insert-br-case1-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-br-case1.html [new file with mode: 0644]
LayoutTests/editing/inserting/insert-br-case2-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-br-case2.html [new file with mode: 0644]
LayoutTests/editing/inserting/insert-br-case3-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-br-case3.html [new file with mode: 0644]
WebCore/ChangeLog-2005-08-23

diff --git a/LayoutTests/editing/inserting/insert-3654864-fix-expected.txt b/LayoutTests/editing/inserting/insert-3654864-fix-expected.txt
new file mode 100644 (file)
index 0000000..bae69b0
--- /dev/null
@@ -0,0 +1,14 @@
+layer at (0,0) size 800x600
+  RenderCanvas 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 {DIV} at (0,0) size 784x84 [border: (2px solid #FF0000)]
+        RenderBR {BR} at (14,14) size 0x28
+        RenderText {TEXT} at (14,42) size 36x28
+          text run at (14,42) width 36: "xxx"
+        RenderBR {BR} at (14,42) size 0x28
+selection is CARET:
+start:      position 3 of child 2 {TEXT} of root {DIV}
+upstream:   position 3 of child 2 {TEXT} of root {DIV}
+downstream: position 0 of child 3 {BR} of root {DIV}
diff --git a/LayoutTests/editing/inserting/insert-3654864-fix.html b/LayoutTests/editing/inserting/insert-3654864-fix.html
new file mode 100644 (file)
index 0000000..9a44ea8
--- /dev/null
@@ -0,0 +1,37 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    selectAllCommand();
+    insertNewlineCommand();
+    for (i = 0; i < 3; i++) {
+        typeCharacterCommand();
+    }
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">Foo    <i>  bar</i></span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/editing/inserting/insert-3659587-fix-expected.txt b/LayoutTests/editing/inserting/insert-3659587-fix-expected.txt
new file mode 100644 (file)
index 0000000..2064201
--- /dev/null
@@ -0,0 +1,18 @@
+layer at (0,0) size 800x600
+  RenderCanvas 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 {DIV} at (0,0) size 784x84 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 108x56
+          RenderInline {B} at (0,0) size 108x56
+            RenderText {TEXT} at (14,14) size 108x28
+              text run at (14,14) width 108: "xxxtestxxx"
+            RenderBR {BR} at (0,0) size 0x0
+            RenderText {TEXT} at (14,42) size 36x28
+              text run at (14,42) width 36: "xxx"
+            RenderBR {BR} at (14,42) size 0x28
+selection is CARET:
+start:      position 3 of child 3 {TEXT} of child 1 {B} of child 1 {SPAN} of root {DIV}
+upstream:   position 3 of child 3 {TEXT} of child 1 {B} of child 1 {SPAN} of root {DIV}
+downstream: position 0 of child 4 {BR} of child 1 {B} of child 1 {SPAN} of root {DIV}
diff --git a/LayoutTests/editing/inserting/insert-3659587-fix.html b/LayoutTests/editing/inserting/insert-3659587-fix.html
new file mode 100644 (file)
index 0000000..21f4844
--- /dev/null
@@ -0,0 +1,45 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    for (i = 0; i < 3; i++) {
+        typeCharacterCommand();
+    }
+    selectAllCommand();
+    boldCommand();
+    moveSelectionForwardByCharacterCommand();
+    for (i = 0; i < 3; i++) {
+        typeCharacterCommand();
+    }
+    insertNewlineCommand();
+    for (i = 0; i < 3; i++) {
+        typeCharacterCommand();
+    }
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">test</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/editing/inserting/insert-after-delete-001-expected.txt b/LayoutTests/editing/inserting/insert-after-delete-001-expected.txt
new file mode 100644 (file)
index 0000000..77f77f5
--- /dev/null
@@ -0,0 +1,12 @@
+layer at (0,0) size 800x600
+  RenderCanvas 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 {DIV} at (0,0) size 784x56 [border: (2px solid #FF0000)]
+        RenderText {TEXT} at (14,14) size 36x28
+          text run at (14,14) width 36: "xxx"
+selection is CARET:
+start:      position 3 of child 1 {TEXT} of root {DIV}
+upstream:   position 3 of child 1 {TEXT} of root {DIV}
+downstream: position 3 of child 1 {TEXT} of root {DIV}
diff --git a/LayoutTests/editing/inserting/insert-after-delete-001.html b/LayoutTests/editing/inserting/insert-after-delete-001.html
new file mode 100644 (file)
index 0000000..dd2f49d
--- /dev/null
@@ -0,0 +1,37 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    selectAllCommand();
+    deleteCommand();
+    for (i = 0; i < 3; i++) {
+        typeCharacterCommand();
+    }
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">test</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/editing/inserting/insert-br-case1-expected.txt b/LayoutTests/editing/inserting/insert-br-case1-expected.txt
new file mode 100644 (file)
index 0000000..9e625d6
--- /dev/null
@@ -0,0 +1,19 @@
+layer at (0,0) size 800x600
+  RenderCanvas 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 {DIV} at (0,0) size 784x84 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 34x28
+          RenderText {TEXT} at (14,14) size 34x28
+            text run at (14,14) width 34: "test"
+        RenderText {TEXT} at (48,14) size 6x28
+          text run at (48,14) width 6: " "
+        RenderBR {BR} at (0,0) size 0x0
+        RenderText {TEXT} at (14,42) size 12x28
+          text run at (14,42) width 12: "x"
+        RenderBR {BR} at (14,42) size 0x28
+selection is CARET:
+start:      position 1 of child 5 {TEXT} of root {DIV}
+upstream:   position 1 of child 5 {TEXT} of root {DIV}
+downstream: position 0 of child 6 {BR} of root {DIV}
diff --git a/LayoutTests/editing/inserting/insert-br-case1.html b/LayoutTests/editing/inserting/insert-br-case1.html
new file mode 100644 (file)
index 0000000..ba53c2c
--- /dev/null
@@ -0,0 +1,36 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    selectAllCommand();
+    moveSelectionForwardByCharacterCommand();
+    insertNewlineCommand();
+    typeCharacterCommand();
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">test</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/editing/inserting/insert-br-case2-expected.txt b/LayoutTests/editing/inserting/insert-br-case2-expected.txt
new file mode 100644 (file)
index 0000000..5bcbae4
--- /dev/null
@@ -0,0 +1,20 @@
+layer at (0,0) size 800x600
+  RenderCanvas 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 {DIV} at (0,0) size 784x112 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 34x84
+          RenderText {TEXT} at (14,14) size 34x28
+            text run at (14,14) width 34: "test"
+          RenderBR {BR} at (0,0) size 0x0
+          RenderText {TEXT} at (14,42) size 12x28
+            text run at (14,42) width 12: "x"
+          RenderBR {BR} at (14,42) size 0x28
+          RenderText {TEXT} at (14,70) size 34x28
+            text run at (14,70) width 34: "test"
+        RenderText {TEXT} at (0,0) size 0x0
+selection is CARET:
+start:      position 1 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+upstream:   position 1 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+downstream: position 0 of child 4 {BR} of child 2 {SPAN} of root {DIV}
diff --git a/LayoutTests/editing/inserting/insert-br-case2.html b/LayoutTests/editing/inserting/insert-br-case2.html
new file mode 100644 (file)
index 0000000..f5d2805
--- /dev/null
@@ -0,0 +1,36 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    for (i = 0; i < 4; i++)
+        moveSelectionForwardByCharacterCommand();
+    insertNewlineCommand();
+    typeCharacterCommand();
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">test<br>test</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/editing/inserting/insert-br-case3-expected.txt b/LayoutTests/editing/inserting/insert-br-case3-expected.txt
new file mode 100644 (file)
index 0000000..9002bf3
--- /dev/null
@@ -0,0 +1,17 @@
+layer at (0,0) size 800x600
+  RenderCanvas 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 {DIV} at (0,0) size 784x84 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 46x56
+          RenderText {TEXT} at (14,14) size 34x28
+            text run at (14,14) width 34: "test"
+          RenderBR {BR} at (0,0) size 0x0
+          RenderText {TEXT} at (14,42) size 46x28
+            text run at (14,42) width 46: "xtest"
+        RenderText {TEXT} at (0,0) size 0x0
+selection is CARET:
+start:      position 1 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+upstream:   position 1 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+downstream: position 1 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
diff --git a/LayoutTests/editing/inserting/insert-br-case3.html b/LayoutTests/editing/inserting/insert-br-case3.html
new file mode 100644 (file)
index 0000000..3ea2358
--- /dev/null
@@ -0,0 +1,36 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    for (i = 0; i < 4; i++)
+        moveSelectionForwardByCharacterCommand();
+    insertNewlineCommand();
+    typeCharacterCommand();
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">testtest</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
index 202290b2065eba3894acf61eb92efa270672f401..3733cb27e1d7e44f4103e3b41c1e26a49703e28d 100644 (file)
@@ -1,3 +1,22 @@
+2004-06-14  Ken Kocienda  <kocienda@apple.com>
+
+        Reviewed by me
+        
+        Added a few more editing-related layout tests.
+
+        * layout-tests/editing/inserting/insert-3654864-fix-expected.txt: Added.
+        * layout-tests/editing/inserting/insert-3654864-fix.html: Added.
+        * layout-tests/editing/inserting/insert-3659587-fix-expected.txt: Added.
+        * layout-tests/editing/inserting/insert-3659587-fix.html: Added.
+        * layout-tests/editing/inserting/insert-after-delete-001-expected.txt: Added.
+        * layout-tests/editing/inserting/insert-after-delete-001.html: Added.
+        * layout-tests/editing/inserting/insert-br-case1-expected.txt: Added.
+        * layout-tests/editing/inserting/insert-br-case1.html: Added.
+        * layout-tests/editing/inserting/insert-br-case2-expected.txt: Added.
+        * layout-tests/editing/inserting/insert-br-case2.html: Added.
+        * layout-tests/editing/inserting/insert-br-case3-expected.txt: Added.
+        * layout-tests/editing/inserting/insert-br-case3.html: Added.
+
 2004-06-14  Ken Kocienda  <kocienda@apple.com>
 
         Reviewed by me