Commit b9837e1a authored by rniwa@webkit.org's avatar rniwa@webkit.org

2011-04-07 Ryosuke Niwa <rniwa@webkit.org>

        Reviewed by Eric Seidel.

        Convert insert-div-021.html to a dump-as-markup test
        https://bugs.webkit.org/show_bug.cgi?id=58019

        Converted the test.

        * editing/inserting/insert-div-021-expected.txt: Added.
        * editing/inserting/insert-div-021.html:
        * platform/chromium-linux/editing/inserting/insert-div-021-expected.checksum: Removed.
        * platform/chromium-linux/editing/inserting/insert-div-021-expected.png: Removed.
        * platform/chromium-win/editing/inserting/insert-div-021-expected.checksum: Removed.
        * platform/chromium-win/editing/inserting/insert-div-021-expected.png: Removed.
        * platform/chromium-win/editing/inserting/insert-div-021-expected.txt: Removed.
        * platform/gtk/editing/inserting/insert-div-021-expected.checksum: Removed.
        * platform/gtk/editing/inserting/insert-div-021-expected.png: Removed.
        * platform/gtk/editing/inserting/insert-div-021-expected.txt: Removed.
        * platform/mac/editing/inserting/insert-div-021-expected.checksum: Removed.
        * platform/mac/editing/inserting/insert-div-021-expected.png: Removed.
        * platform/mac/editing/inserting/insert-div-021-expected.txt: Removed.
        * platform/qt/editing/inserting/insert-div-021-expected.txt: Removed.

git-svn-id: svn://svn.chromium.org/blink/trunk@83161 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 11913715
2011-04-07 Ryosuke Niwa <rniwa@webkit.org>
Reviewed by Eric Seidel.
Convert insert-div-021.html to a dump-as-markup test
https://bugs.webkit.org/show_bug.cgi?id=58019
Converted the test.
* editing/inserting/insert-div-021-expected.txt: Added.
* editing/inserting/insert-div-021.html:
* platform/chromium-linux/editing/inserting/insert-div-021-expected.checksum: Removed.
* platform/chromium-linux/editing/inserting/insert-div-021-expected.png: Removed.
* platform/chromium-win/editing/inserting/insert-div-021-expected.checksum: Removed.
* platform/chromium-win/editing/inserting/insert-div-021-expected.png: Removed.
* platform/chromium-win/editing/inserting/insert-div-021-expected.txt: Removed.
* platform/gtk/editing/inserting/insert-div-021-expected.checksum: Removed.
* platform/gtk/editing/inserting/insert-div-021-expected.png: Removed.
* platform/gtk/editing/inserting/insert-div-021-expected.txt: Removed.
* platform/mac/editing/inserting/insert-div-021-expected.checksum: Removed.
* platform/mac/editing/inserting/insert-div-021-expected.png: Removed.
* platform/mac/editing/inserting/insert-div-021-expected.txt: Removed.
* platform/qt/editing/inserting/insert-div-021-expected.txt: Removed.
2011-04-07 Adam Barth <abarth@webkit.org> 2011-04-07 Adam Barth <abarth@webkit.org>
Reviewed by Eric Seidel. Reviewed by Eric Seidel.
EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of BODY > HTML > #document to 9 of BODY > HTML > #document EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 6 of DIV > BODY > HTML > #document
EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 0 of DIV > DIV > BODY > HTML > #document to 0 of DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: shouldDeleteDOMRange:range from 6 of BODY > HTML > #document to 7 of BODY > HTML > #document EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE EDITING DELEGATE: shouldDeleteDOMRange:range from 4 of DIV > BODY > HTML > #document to 5 of DIV > BODY > HTML > #document
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > DIV > BODY > HTML > #document to 3 of #text > SPAN > DIV > BODY > HTML > #document toDOMRange:range from 3 of #text > SPAN > DIV > BODY > HTML > #document to 3 of #text > SPAN > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > DIV > BODY > HTML > #document to 3 of #text > SPAN > DIV > BODY > HTML > #document toDOMRange:range from 0 of DIV > DIV > BODY > HTML > #document to 0 of DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
layer at (0,0) size 800x600 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
RenderView at (0,0) size 800x600 EDITING DELEGATE: webViewDidEndEditing:WebViewDidEndEditingNotification
layer at (0,0) size 800x600 Test inserting paragraphs: should see "foo", then an empty line, then "bar" in the next line.
RenderBlock {HTML} at (0,0) size 800x600 Fix for this bug: <rdar://problem/3924579> REGRESSION (Mail): After deleting, hitting return key does not insert visible newline
RenderBody {BODY} at (8,8) size 784x584 | "
RenderBlock (anonymous) at (0,0) size 784x112 "
RenderText {#text} at (0,0) size 782x56 | <div>
text run at (0,0) width 776: "Test inserting paragraphs: should see \"foo\", then an empty blue box, then a blue" | style="border: none; height: 12px"
text run at (776,0) width 6: " " | "
text run at (0,28) width 410: "box with with \"bar\" in it. Fix for this bug: " "
RenderInline {A} at (0,0) size 260x28 [color=#0000EE] | <span>
RenderText {#text} at (410,28) size 260x28 | id="test"
text run at (410,28) width 260: "<rdar://problem/3924579>" | "foo"
RenderText {#text} at (670,28) size 769x84 | <div>
text run at (670,28) width 6: " " | <br>
text run at (0,56) width 763: "REGRESSION (Mail): After deleting, hitting return key does not insert visible" | <div>
text run at (763,56) width 6: " " | <span>
text run at (0,84) width 77: "newline" | id="test"
RenderBlock {DIV} at (0,112) size 784x36 | "<#selection-caret>bar
RenderBlock (anonymous) at (0,148) size 784x28 "
RenderInline {SPAN} at (0,0) size 32x28
RenderText {#text} at (0,0) size 32x28
text run at (0,0) width 32: "foo"
RenderBlock {DIV} at (0,176) size 784x56 [border: (2px solid #0000FF)]
RenderBR {BR} at (14,14) size 0x28
RenderBlock {DIV} at (0,232) size 784x56 [border: (2px solid #0000FF)]
RenderInline {SPAN} at (0,0) size 0x0
RenderText {#text} at (14,14) size 31x28
text run at (14,14) width 31: "bar"
caret: position 0 of child 1 {#text} of child 7 {DIV} of body
<html> <!DOCTYPE html>
<head> <html>
<body>
<style> <div contenteditable id="root" style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space;">
body { <div style="border: none; height: 12px"></div>
font-size: 24px; <span id="test">foo</span><br>bar
} </div>
.editing { <script src="../../resources/dump-as-markup.js"></script>
border: 2px solid red;
padding: 12px;
}
div {
border: 2px solid blue;
padding: 12px;
}
</style>
<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
<script> <script>
function editingTest() { if (window.layoutTestController)
for (i = 0; i < 4; i++) layoutTestController.dumpEditingCallbacks();
moveSelectionForwardByCharacterCommand();
deleteCommand();
insertParagraphCommand();
insertParagraphCommand();
}
</script>
<title>Editing Test</title>
</head>
<body contenteditable id="root" style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space;">
Test inserting paragraphs: should see "foo", then an empty blue box, then a blue box with with "bar" in it. Fix for this bug: var root = document.getElementById('root');
<a href="rdar://problem/3924579">&lt;rdar://problem/3924579&gt;</a> REGRESSION (Mail): After deleting, hitting return key does not insert visible newline root.focus();
window.getSelection().setPosition(document.getElementById('test'), 0);
for (i = 0; i < 4; i++)
window.getSelection().modify('move', 'forward', 'character');
<div style="border: none; height: 12px"></div> document.execCommand('Delete');
document.execCommand('InsertParagraph');
document.execCommand('InsertParagraph');
<span id="test">foo</span><br>bar Markup.description('Test inserting paragraphs: should see "foo", then an empty line, then "bar" in the next line.\n'+
'Fix for this bug: <rdar://problem/3924579> REGRESSION (Mail): After deleting, hitting return key does not insert visible newline');
Markup.dump(root);
<script>
runEditingTest();
</script> </script>
</body> </body>
</html> </html>
EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of BODY > HTML > #document to 9 of BODY > HTML > #document
EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: shouldDeleteDOMRange:range from 6 of BODY > HTML > #document to 7 of BODY > HTML > #document
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
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 (anonymous) at (0,0) size 784x112
RenderText {#text} at (0,0) size 772x55
text run at (0,0) width 766: "Test inserting paragraphs: should see \"foo\", then an empty blue box, then a blue"
text run at (766,0) width 6: " "
text run at (0,28) width 402: "box with with \"bar\" in it. Fix for this bug: "
RenderInline {A} at (0,0) size 257x27 [color=#0000EE]
RenderText {#text} at (402,28) size 257x27
text run at (402,28) width 257: "<rdar://problem/3924579>"
RenderText {#text} at (659,28) size 754x83
text run at (659,28) width 6: " "
text run at (0,56) width 748: "REGRESSION (Mail): After deleting, hitting return key does not insert visible"
text run at (748,56) width 6: " "
text run at (0,84) width 75: "newline"
RenderBlock {DIV} at (0,112) size 784x36
RenderBlock (anonymous) at (0,148) size 784x28
RenderInline {SPAN} at (0,0) size 32x27
RenderText {#text} at (0,0) size 32x27
text run at (0,0) width 32: "foo"
RenderBlock {DIV} at (0,176) size 784x56 [border: (2px solid #0000FF)]
RenderBR {BR} at (14,14) size 0x27
RenderBlock {DIV} at (0,232) size 784x56 [border: (2px solid #0000FF)]
RenderInline {SPAN} at (0,0) size 0x0
RenderText {#text} at (14,14) size 31x27
text run at (14,14) width 31: "bar"
caret: position 0 of child 1 {#text} of child 7 {DIV} of body
EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of BODY > HTML > #document to 9 of BODY > HTML > #document
EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: shouldDeleteDOMRange:range from 6 of BODY > HTML > #document to 7 of BODY > HTML > #document
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
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 (anonymous) at (0,0) size 784x112
RenderText {#text} at (0,0) size 782x56
text run at (0,0) width 776: "Test inserting paragraphs: should see \"foo\", then an empty blue box, then a blue"
text run at (776,0) width 6: " "
text run at (0,28) width 410: "box with with \"bar\" in it. Fix for this bug: "
RenderInline {A} at (0,0) size 260x28 [color=#0000EE]
RenderText {#text} at (410,28) size 260x28
text run at (410,28) width 260: "<rdar://problem/3924579>"
RenderText {#text} at (670,28) size 769x84
text run at (670,28) width 6: " "
text run at (0,56) width 763: "REGRESSION (Mail): After deleting, hitting return key does not insert visible"
text run at (763,56) width 6: " "
text run at (0,84) width 77: "newline"
RenderBlock {DIV} at (0,112) size 784x36
RenderBlock (anonymous) at (0,148) size 784x28
RenderInline {SPAN} at (0,0) size 32x28
RenderText {#text} at (0,0) size 32x28
text run at (0,0) width 32: "foo"
RenderBlock {DIV} at (0,176) size 784x56 [border: (2px solid #0000FF)]
RenderBR {BR} at (14,14) size 0x28
RenderBlock {DIV} at (0,232) size 784x56 [border: (2px solid #0000FF)]
RenderInline {SPAN} at (0,0) size 0x0
RenderText {#text} at (14,14) size 31x28
text run at (14,14) width 31: "bar"
caret: position 0 of child 1 {#text} of child 7 {DIV} of body
EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of BODY > HTML > #document to 9 of BODY > HTML > #document
EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: shouldDeleteDOMRange:range from 6 of BODY > HTML > #document to 7 of BODY > HTML > #document
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > SPAN > BODY > HTML > #document to 3 of #text > SPAN > BODY > HTML > #document toDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
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 (anonymous) at (0,0) size 784x124
RenderText {#text} at (0,0) size 779x63
text run at (0,0) width 773: "Test inserting paragraphs: should see \"foo\", then an empty blue box, then a"
text run at (773,0) width 6: " "
text run at (0,31) width 488: "blue box with with \"bar\" in it. Fix for this bug: "
RenderInline {A} at (0,0) size 275x32 [color=#0000EE]
RenderText {#text} at (488,31) size 275x32
text run at (488,31) width 275: "<rdar://problem/3924579>"
RenderText {#text} at (763,31) size 769x94
text run at (763,31) width 6: " "
text run at (0,62) width 734: "REGRESSION (Mail): After deleting, hitting return key does not insert"
text run at (734,62) width 6: " "
text run at (0,93) width 151: "visible newline"
RenderBlock {DIV} at (0,124) size 784x36
RenderBlock (anonymous) at (0,160) size 784x31
RenderInline {SPAN} at (0,0) size 32x32
RenderText {#text} at (0,0) size 32x32
text run at (0,0) width 32: "foo"
RenderBlock {DIV} at (0,191) size 784x59 [border: (2px solid #0000FF)]
RenderBR {BR} at (14,14) size 0x32
RenderBlock {DIV} at (0,250) size 784x59 [border: (2px solid #0000FF)]
RenderInline {SPAN} at (0,0) size 0x0
RenderText {#text} at (14,14) size 36x32
text run at (14,14) width 36: "bar"
caret: position 0 of child 1 {#text} of child 7 {DIV} of body
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment