Reviewed by Hyatt.
authordarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Feb 2006 04:44:31 +0000 (04:44 +0000)
committerdarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Feb 2006 04:44:31 +0000 (04:44 +0000)
        - test for http://bugzilla.opendarwin.org/show_bug.cgi?id=7095
          Removing positioning from an element does not relayout properly

        * fast/block/positioning/relayout-on-position-change-expected.checksum: Added.
        * fast/block/positioning/relayout-on-position-change-expected.png: Added.
        * fast/block/positioning/relayout-on-position-change-expected.txt: Added.
        * fast/block/positioning/relayout-on-position-change.html: Added.

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

LayoutTests/ChangeLog
LayoutTests/fast/block/positioning/relayout-on-position-change-expected.checksum [new file with mode: 0644]
LayoutTests/fast/block/positioning/relayout-on-position-change-expected.png [new file with mode: 0644]
LayoutTests/fast/block/positioning/relayout-on-position-change-expected.txt [new file with mode: 0644]
LayoutTests/fast/block/positioning/relayout-on-position-change.html [new file with mode: 0644]

index af5cc3f2f9db8c178b5cafa8460d104e259f6765..89836a71a60409c9f08dc7b923b26dfbdeae474c 100644 (file)
@@ -1,3 +1,15 @@
+2006-02-08  Mitz Pettel  <opendarwin.org@mitzpettel.com>
+
+        Reviewed by Hyatt.
+
+        - test for http://bugzilla.opendarwin.org/show_bug.cgi?id=7095
+          Removing positioning from an element does not relayout properly
+
+        * fast/block/positioning/relayout-on-position-change-expected.checksum: Added.
+        * fast/block/positioning/relayout-on-position-change-expected.png: Added.
+        * fast/block/positioning/relayout-on-position-change-expected.txt: Added.
+        * fast/block/positioning/relayout-on-position-change.html: Added.
+
 2006-02-08  Maciej Stachowiak  <mjs@apple.com>
 
         - added SVG path hit testing test
 2006-02-08  Maciej Stachowiak  <mjs@apple.com>
 
         - added SVG path hit testing test
diff --git a/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.checksum b/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.checksum
new file mode 100644 (file)
index 0000000..ced0949
--- /dev/null
@@ -0,0 +1,2 @@
+d55ebae796ea4edb58b8ca0a823c7834
+\ No newline at end of file
diff --git a/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.png b/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.png
new file mode 100644 (file)
index 0000000..643660d
Binary files /dev/null and b/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.png differ
diff --git a/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.txt b/LayoutTests/fast/block/positioning/relayout-on-position-change-expected.txt
new file mode 100644 (file)
index 0000000..4304b75
--- /dev/null
@@ -0,0 +1,25 @@
+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 {P} at (0,0) size 784x36
+        RenderText {TEXT} at (0,0) size 212x18
+          text run at (0,0) width 212: "This tests for a regression against "
+        RenderInline {I} at (0,0) size 756x36
+          RenderInline {A} at (0,0) size 348x18 [color=#0000EE]
+            RenderText {TEXT} at (212,0) size 348x18
+              text run at (212,0) width 348: "http://bugzilla.opendarwin.org/show_bug.cgi?id=7095"
+          RenderText {TEXT} at (560,0) size 756x36
+            text run at (560,0) width 4: " "
+            text run at (564,0) width 192: "Removing positioning from an"
+            text run at (0,18) width 220: "element does not relayout properly"
+        RenderText {TEXT} at (220,18) size 4x18
+          text run at (220,18) width 4: "."
+      RenderBlock {P} at (0,52) size 784x18
+        RenderText {TEXT} at (0,0) size 373x18
+          text run at (0,0) width 373: "The green square should be to the left of the yellow square."
+      RenderBlock {HR} at (0,86) size 784x2 [border: (1px inset #000000)]
+layer at (8,104) size 200x100
+  RenderBlock (relative positioned) {DIV} at (0,96) size 200x100 [bgcolor=#FFFF00]
+    RenderBlock {DIV} at (0,0) size 100x100 [bgcolor=#008000]
diff --git a/LayoutTests/fast/block/positioning/relayout-on-position-change.html b/LayoutTests/fast/block/positioning/relayout-on-position-change.html
new file mode 100644 (file)
index 0000000..10ae5e2
--- /dev/null
@@ -0,0 +1,25 @@
+<html>
+<head>
+<script>
+function test()
+{
+    document.body.offsetTop;    // force layout
+    document.getElementById('change').style.position = "none";
+}
+</script>
+</head>
+<body onload="test();">
+<p>
+    This tests for a regression against
+    <i><a href="http://bugzilla.opendarwin.org/show_bug.cgi?id=7095">http://bugzilla.opendarwin.org/show_bug.cgi?id=7095</a>
+    Removing positioning from an element does not relayout properly</i>.
+</p>
+<p>
+    The green square should be to the left of the yellow square.
+</p>
+<hr>
+<div style="background: yellow; position: relative; width: 200; height: 100;">
+<div id="change" style="background: green; position: absolute; top: 0; left: 100; width: 100; height: 100">
+</div>
+</div>
+</body>