Commit 447f2722 authored by eric@webkit.org's avatar eric@webkit.org
Browse files

2009-12-02 Shinichiro Hamaji <hamaji@chromium.org>

        Reviewed by Darin Adler.

        Rewrite two tests with dumpAsText
        https://bugs.webkit.org/show_bug.cgi?id=32014

        * fast/block/positioning/complex-percentage-height-expected.txt: Added.
        * fast/block/positioning/complex-percentage-height.html:
        * fast/lists/item-not-in-list-line-wrapping-expected.txt: Added.
        * fast/lists/item-not-in-list-line-wrapping.html:
        * platform/mac/fast/block/positioning/complex-percentage-height-expected.checksum: Removed.
        * platform/mac/fast/block/positioning/complex-percentage-height-expected.png: Removed.
        * platform/mac/fast/block/positioning/complex-percentage-height-expected.txt: Removed.
        * platform/mac/fast/lists/item-not-in-list-line-wrapping-expected.checksum: Removed.
        * platform/mac/fast/lists/item-not-in-list-line-wrapping-expected.png: Removed.
        * platform/mac/fast/lists/item-not-in-list-line-wrapping-expected.txt: Removed.
        * platform/qt/Skipped:
        * platform/qt/fast/block/positioning/complex-percentage-height-expected.txt: Removed.
        * platform/qt/fast/lists/item-not-in-list-line-wrapping-expected.txt: Removed.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51626 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent f9c8ff35
2009-12-02 Shinichiro Hamaji <hamaji@chromium.org>
Reviewed by Darin Adler.
Rewrite two tests with dumpAsText
https://bugs.webkit.org/show_bug.cgi?id=32014
* fast/block/positioning/complex-percentage-height-expected.txt: Added.
* fast/block/positioning/complex-percentage-height.html:
* fast/lists/item-not-in-list-line-wrapping-expected.txt: Added.
* fast/lists/item-not-in-list-line-wrapping.html:
* platform/mac/fast/block/positioning/complex-percentage-height-expected.checksum: Removed.
* platform/mac/fast/block/positioning/complex-percentage-height-expected.png: Removed.
* platform/mac/fast/block/positioning/complex-percentage-height-expected.txt: Removed.
* platform/mac/fast/lists/item-not-in-list-line-wrapping-expected.checksum: Removed.
* platform/mac/fast/lists/item-not-in-list-line-wrapping-expected.png: Removed.
* platform/mac/fast/lists/item-not-in-list-line-wrapping-expected.txt: Removed.
* platform/qt/Skipped:
* platform/qt/fast/block/positioning/complex-percentage-height-expected.txt: Removed.
* platform/qt/fast/lists/item-not-in-list-line-wrapping-expected.txt: Removed.
2009-12-02 Alexey Proskuryakov <ap@apple.com>
 
Reviewed by Darin Fisher.
Test case:
Blue div has 400px width, dynamic height, and position: relative.
Inside blue div there are 3 other div with height: 40px (and has some bottom margin..)
the height of the blue div expands with the green divs inside..
Yellow div has position absolute (and positioned in the top left corner of the blue div)
it's height set to 100%
the height of the yellow div now equals with the height of the blue div
Red div is inserted into the yellow div, and it's height set to 100%
Problem:
The height of the red div should equals to the height of the blue (and yellow) div.
It works right with Opera 9.2, Firefox 2, Camino 1.0.4 and Internet Explorer 7.
Workaround:
If you set position absolute to the red div, it's height will expands along with the blue div.
Result:
PASS: redHeight == yellowHeight
PASS: redHeight == blueHeight
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<style type="text/css" media="screen">
* {
margin: 0;
padding: 0;
}
/* -------- Test case ---------- */
#warper {
margin: 40px;
width: 400px;
border: 3px solid blue;
position: relative;
height: auto;
}
.fill {
height: 40px;
margin-bottom: 10px;
background-color: green;
}
#abs_100_height {
height: 100%;
width: 200px;
position: absolute;
top: 0;
left: 0;
border: 3px solid yellow;
}
#abs_100_height div {
height: 100%;
border: 3px dashed red;
}
/* -------- Test case ends ---------- */
#desc {
margin: 100px 0 0 50px;
}
h3 {
margin-bottom: 5px;
}
ul {
list-style-position: inside;
margin-bottom: 20px;
}
li {
margin-bottom: 7px;
}
p {
margin-bottom: 20px;
}
</style>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<style type="text/css" media="screen">
* {
margin: 0;
padding: 0;
}
/* -------- Test case ---------- */
#warper {
margin: 40px;
width: 400px;
border: 3px solid blue;
position: relative;
height: auto;
}
.fill {
height: 40px;
margin-bottom: 10px;
background-color: green;
}
#abs_100_height {
height: 100%;
width: 200px;
position: absolute;
top: 0;
left: 0;
border: 3px solid yellow;
}
#abs_100_height div {
height: 100%;
border: 3px dashed red;
}
/* -------- Test case ends ---------- */
#desc {
margin: 100px 0 0 50px;
}
h3 {
margin-bottom: 5px;
}
ul {
list-style-position: inside;
margin-bottom: 20px;
}
li {
margin-bottom: 7px;
}
p {
margin-bottom: 20px;
}
</style>
</head>
<body>
<!-- Test case -->
<div id="warper">
<div class="fill"></div>
<div class="fill"></div>
<div class="fill"></div>
<div id="abs_100_height">
<div></div>
</div>
</div>
<!-- Test case ends -->
<div id="desc">
<h3>Test case:</h3>
<ul>
<li>
Blue div has 400px width, dynamic height, and position: relative.
</li>
<li>
Inside blue div there are 3 other div with height: 40px (and has some bottom margin..)<br>
the height of the blue div expands with the green divs inside..
</li>
<li>
Yellow div has position absolute (and positioned in the top left corner of the blue div)<br>
it's height set to 100%<br>
the height of the yellow div now equals with the height of the blue div
</li>
<li>
Red div is inserted into the yellow div, and it's height set to 100%
</li>
</ul>
<h3>Problem:</h3>
<p>
The height of the red div <strong>should equals</strong> to the height of the blue (and yellow) div.<br>
It works right with Opera 9.2, Firefox 2, Camino 1.0.4 and Internet Explorer 7.
</p>
<h3>Workaround:</h3>
<p>
If you set position absolute to the red div, it's height will expands along with the blue div.
</p>
</div>
</body>
</html>
\ No newline at end of file
<body>
<!-- Test case -->
<div id="warper">
<div class="fill"></div>
<div class="fill"></div>
<div class="fill"></div>
<div id="abs_100_height">
<div id="inner_abs_100_height"></div>
</div>
</div>
<!-- Test case ends -->
<div id="desc">
<h3>Test case:</h3>
<ul>
<li>
Blue div has 400px width, dynamic height, and position: relative.
</li>
<li>
Inside blue div there are 3 other div with height: 40px (and has some bottom margin..)<br>
the height of the blue div expands with the green divs inside..
</li>
<li>
Yellow div has position absolute (and positioned in the top left corner of the blue div)<br>
it's height set to 100%<br>
the height of the yellow div now equals with the height of the blue div
</li>
<li>
Red div is inserted into the yellow div, and it's height set to 100%
</li>
</ul>
<h3>Problem:</h3>
<p>
The height of the red div <strong>should equals</strong> to the height of the blue (and yellow) div.<br>
It works right with Opera 9.2, Firefox 2, Camino 1.0.4 and Internet Explorer 7.
</p>
<h3>Workaround:</h3>
<p>
If you set position absolute to the red div, it's height will expands along with the blue div.
</p>
<h3>Result:</h3>
<div id="result"></div>
</div>
<script>
function gebi(id)
{
return document.getElementById(id);
}
function addResult(color, message)
{
var result = gebi("result");
var div = document.createElement("div");
div.style.color = color;
div.appendChild(document.createTextNode(message));
result.appendChild(div);
}
var blueHeight = gebi("warper").offsetHeight;
var yellowHeight = gebi("abs_100_height").offsetHeight;
var redHeight = gebi("inner_abs_100_height").offsetHeight;
if (redHeight == yellowHeight)
addResult("green", "PASS: redHeight == yellowHeight");
else
addResult("red", "FAILED: redHeight (" + redHeight + ") != yellowHeight (" + yellowHeight + ")");
if (redHeight == blueHeight)
addResult("green", "PASS: redHeight == blueHeight");
else
addResult("red", "FAILED: redHeight (" + redHeight + ") != blueHeight (" + blueHeight + ")");
if (window.layoutTestController)
layoutTestController.dumpAsText();
</script>
</body>
</html>
Test for http://bugs.webkit.org/show_bug.cgi?id=12746 REGRESSION (r13853): List item's first line overflows containing div.
Text should not overflow the yellow box.
Lorem ipsum dolor sit amet
PASS
......@@ -11,9 +11,22 @@
Text should not overflow the yellow box.
</p>
<div style="background-color:yellow; width: 125px;">
<li>
<li><span id="text">
Lorem ipsum dolor sit amet
</li>
</span></li>
</div>
<div id="result">
</div>
<script>
var result = document.getElementById("result");
var text = document.getElementById("text");
if (text.offsetWidth <= 125)
result.innerHTML = "PASS";
else
result.innerHTML = "FAILED: text.offsetWidth=" + text.offsetWidth;
if (window.layoutTestController)
layoutTestController.dumpAsText();
</script>
</body>
</html>
layer at (0,0) size 785x638
RenderView at (0,0) size 785x600
layer at (0,0) size 785x638
RenderBlock {HTML} at (0,0) size 785x638
RenderBody {BODY} at (0,40) size 785x578
RenderBlock {DIV} at (50,256) size 735x322
RenderBlock {H3} at (0,0) size 735x22
RenderText {#text} at (0,0) size 78x22
text run at (0,0) width 78: "Test case:"
RenderBlock {UL} at (0,27) size 735x147
RenderListItem {LI} at (0,0) size 735x18
RenderListMarker at (-1,0) size 7x18: bullet
RenderText {#text} at (14,0) size 411x18
text run at (14,0) width 411: "Blue div has 400px width, dynamic height, and position: relative."
RenderListItem {LI} at (0,25) size 735x36
RenderListMarker at (-1,0) size 7x18: bullet
RenderText {#text} at (14,0) size 541x18
text run at (14,0) width 541: "Inside blue div there are 3 other div with height: 40px (and has some bottom margin..)"
RenderBR {BR} at (555,0) size 0x18
RenderText {#text} at (0,18) size 386x18
text run at (0,18) width 386: "the height of the blue div expands with the green divs inside.."
RenderListItem {LI} at (0,68) size 735x54
RenderListMarker at (-1,0) size 7x18: bullet
RenderText {#text} at (14,0) size 538x18
text run at (14,0) width 538: "Yellow div has position absolute (and positioned in the top left corner of the blue div)"
RenderBR {BR} at (552,0) size 0x18
RenderText {#text} at (0,18) size 138x18
text run at (0,18) width 138: "it's height set to 100%"
RenderBR {BR} at (138,18) size 0x18
RenderText {#text} at (0,36) size 442x18
text run at (0,36) width 442: "the height of the yellow div now equals with the height of the blue div"
RenderListItem {LI} at (0,129) size 735x18
RenderListMarker at (-1,0) size 7x18: bullet
RenderText {#text} at (14,0) size 412x18
text run at (14,0) width 412: "Red div is inserted into the yellow div, and it's height set to 100%"
RenderBlock {H3} at (0,194) size 735x22
RenderText {#text} at (0,0) size 76x22
text run at (0,0) width 76: "Problem:"
RenderBlock {P} at (0,221) size 735x36
RenderText {#text} at (0,0) size 160x18
text run at (0,0) width 160: "The height of the red div "
RenderInline {STRONG} at (0,0) size 92x18
RenderText {#text} at (160,0) size 92x18
text run at (160,0) width 92: "should equals"
RenderText {#text} at (252,0) size 265x18
text run at (252,0) width 265: " to the height of the blue (and yellow) div."
RenderBR {BR} at (517,0) size 0x18
RenderText {#text} at (0,18) size 498x18
text run at (0,18) width 498: "It works right with Opera 9.2, Firefox 2, Camino 1.0.4 and Internet Explorer 7."
RenderBlock {H3} at (0,277) size 735x22
RenderText {#text} at (0,0) size 115x22
text run at (0,0) width 115: "Workaround:"
RenderBlock {P} at (0,304) size 735x18
RenderText {#text} at (0,0) size 561x18
text run at (0,0) width 561: "If you set position absolute to the red div, it's height will expands along with the blue div."
layer at (40,40) size 406x156
RenderBlock (relative positioned) {DIV} at (40,0) size 406x156 [border: (3px solid #0000FF)]
RenderBlock {DIV} at (3,3) size 400x40 [bgcolor=#008000]
RenderBlock {DIV} at (3,53) size 400x40 [bgcolor=#008000]
RenderBlock {DIV} at (3,103) size 400x40 [bgcolor=#008000]
layer at (43,43) size 206x159
RenderBlock (positioned) {DIV} at (3,3) size 206x156 [border: (3px solid #FFFF00)]
RenderBlock {DIV} at (3,3) size 200x156 [border: (3px dashed #FF0000)]
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 53x18
text run at (0,0) width 53: "Test for "
RenderInline {I} at (0,0) size 777x36
RenderInline {A} at (0,0) size 301x18 [color=#0000EE]
RenderText {#text} at (53,0) size 301x18
text run at (53,0) width 301: "http://bugs.webkit.org/show_bug.cgi?id=12746"
RenderText {#text} at (354,0) size 777x36
text run at (354,0) width 4: " "
text run at (358,0) width 419: "REGRESSION (r13853): List item's first line overflows containing"
text run at (0,18) width 19: "div"
RenderText {#text} at (19,18) size 4x18
text run at (19,18) width 4: "."
RenderBlock {P} at (0,52) size 784x18
RenderText {#text} at (0,0) size 262x18
text run at (0,0) width 262: "Text should not overflow the yellow box."
RenderBlock {DIV} at (0,86) size 125x36 [bgcolor=#FFFF00]
RenderListItem {LI} at (0,0) size 125x36
RenderListMarker at (-1,0) size 7x18: bullet
RenderText {#text} at (14,0) size 98x36
text run at (14,0) width 84: "Lorem ipsum"
text run at (0,18) width 85: "dolor sit amet"
......@@ -5281,6 +5281,3 @@ fast/css/namespaces/namespaces-empty.xml
# Failure introduced by http://trac.webkit.org/changeset/51429
# hamaji will look into this.
editing/selection/last-empty-inline.html
fast/block/positioning/complex-percentage-height.html
fast/lists/item-not-in-list-line-wrapping.html
layer at (0,0) size 800x652
RenderView at (0,0) size 800x600
layer at (0,0) size 800x652
RenderBlock {HTML} at (0,0) size 800x652
RenderBody {BODY} at (0,40) size 800x592
RenderBlock {DIV} at (50,256) size 750x336
RenderBlock {H3} at (0,0) size 750x23
RenderText {#text} at (0,0) size 78x22
text run at (0,0) width 78: "Test case:"
RenderBlock {UL} at (0,28) size 750x154
RenderListItem {LI} at (0,0) size 750x19
RenderListMarker at (-1,0) size 7x19: bullet
RenderText {#text} at (14,0) size 408x19
text run at (14,0) width 4: " "
text run at (18,0) width 404: "Blue div has 400px width, dynamic height, and position: relative."
RenderListItem {LI} at (0,26) size 750x38
RenderListMarker at (-1,0) size 7x19: bullet
RenderText {#text} at (14,0) size 547x19
text run at (14,0) width 4: " "
text run at (18,0) width 543: "Inside blue div there are 3 other div with height: 40px (and has some bottom margin..)"
RenderBR {BR} at (561,0) size 0x19
RenderText {#text} at (0,19) size 386x19
text run at (0,19) width 386: "the height of the blue div expands with the green divs inside.."
RenderListItem {LI} at (0,71) size 750x57
RenderListMarker at (-1,0) size 7x19: bullet
RenderText {#text} at (14,0) size 536x19
text run at (14,0) width 4: " "
text run at (18,0) width 532: "Yellow div has position absolute (and positioned in the top left corner of the blue div)"
RenderBR {BR} at (550,0) size 0x19
RenderText {#text} at (0,19) size 139x19
text run at (0,19) width 139: "it's height set to 100%"
RenderBR {BR} at (139,19) size 0x19
RenderText {#text} at (0,38) size 433x19
text run at (0,38) width 433: "the height of the yellow div now equals with the height of the blue div"
RenderListItem {LI} at (0,135) size 750x19
RenderListMarker at (-1,0) size 7x19: bullet
RenderText {#text} at (14,0) size 412x19
text run at (14,0) width 4: " "
text run at (18,0) width 408: "Red div is inserted into the yellow div, and it's height set to 100%"
RenderBlock {H3} at (0,202) size 750x23
RenderText {#text} at (0,0) size 69x22
text run at (0,0) width 69: "Problem:"
RenderBlock {P} at (0,230) size 750x39
RenderText {#text} at (0,0) size 159x19
text run at (0,0) width 159: "The height of the red div "
RenderInline {STRONG} at (0,0) size 98x20
RenderText {#text} at (159,0) size 98x20
text run at (159,0) width 98: "should equals"
RenderText {#text} at (257,0) size 261x19
text run at (257,0) width 261: " to the height of the blue (and yellow) div."
RenderBR {BR} at (518,0) size 0x19
RenderText {#text} at (0,20) size 489x19
text run at (0,20) width 489: "It works right with Opera 9.2, Firefox 2, Camino 1.0.4 and Internet Explorer 7."
RenderBlock {H3} at (0,289) size 750x23
RenderText {#text} at (0,0) size 100x22
text run at (0,0) width 100: "Workaround:"
RenderBlock {P} at (0,317) size 750x19
RenderText {#text} at (0,0) size 554x19
text run at (0,0) width 554: "If you set position absolute to the red div, it's height will expands along with the blue div."
layer at (40,40) size 406x156
RenderBlock (relative positioned) {DIV} at (40,0) size 406x156 [border: (3px solid #0000FF)]
RenderBlock {DIV} at (3,3) size 400x40 [bgcolor=#008000]
RenderBlock {DIV} at (3,53) size 400x40 [bgcolor=#008000]
RenderBlock {DIV} at (3,103) size 400x40 [bgcolor=#008000]
layer at (43,43) size 206x159
RenderBlock (positioned) {DIV} at (3,3) size 206x156 [border: (3px solid #FFFF00)]
RenderBlock {DIV} at (3,3) size 200x156 [border: (3px dashed #FF0000)]
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 53x19
text run at (0,0) width 53: "Test for "
RenderInline {I} at (0,0) size 759x39
RenderInline {A} at (0,0) size 294x19 [color=#0000EE]
RenderText {#text} at (53,0) size 294x19
text run at (53,0) width 294: "http://bugs.webkit.org/show_bug.cgi?id=12746"
RenderText {#text} at (347,0) size 759x39
text run at (347,0) width 4: " "
text run at (351,0) width 408: "REGRESSION (r13853): List item's first line overflows containing"
text run at (0,20) width 18: "div"
RenderText {#text} at (18,20) size 4x19
text run at (18,20) width 4: "."
RenderBlock {P} at (0,54) size 784x19
RenderText {#text} at (0,0) size 253x19
text run at (0,0) width 253: "Text should not overflow the yellow box."
RenderBlock {DIV} at (0,87) size 125x38 [bgcolor=#FFFF00]
RenderListItem {LI} at (0,0) size 125x38
RenderListMarker at (-1,0) size 7x19: bullet
RenderText {#text} at (14,0) size 101x38
text run at (14,0) width 4: " "
text run at (18,0) width 83: "Lorem ipsum"
text run at (0,19) width 86: "dolor sit amet"
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