summaryrefslogtreecommitdiffstats
path: root/layout/reftests/position-dynamic-changes/vertical
diff options
context:
space:
mode:
Diffstat (limited to 'layout/reftests/position-dynamic-changes/vertical')
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/animate.js59
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightA-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA-2.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN-2.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightN-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest.list18
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest.listbackup12
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_border_abspos.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_border_parent.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_margin_abspos.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_margin_parent.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_padding_abspos.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_padding_parent.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/reftest_plain.list20
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/style.css19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN.html19
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA-ref.html15
-rw-r--r--layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA.html19
43 files changed, 808 insertions, 0 deletions
diff --git a/layout/reftests/position-dynamic-changes/vertical/animate.js b/layout/reftests/position-dynamic-changes/vertical/animate.js
new file mode 100644
index 0000000000..a53d6a1800
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/animate.js
@@ -0,0 +1,59 @@
+var currentOffset = null;
+var maxOffset = null;
+var property = "top";
+
+var rfa = null;
+if (window.requestAnimationFrame) {
+ rfa = requestAnimationFrame;
+} else if (window.webkitRequestAnimationFrame) {
+ rfa = webkitRequestAnimationFrame;
+} else if (window.msRequestAnimationFrame) {
+ rfa = msRequestAnimationFrame;
+} else if (window.oRequestAnimationFrame) {
+ rfa = oRequestAnimationFrame;
+}
+
+function animate(from, to, prop) {
+ currentOffset = from;
+ maxOffset = to;
+ if (prop) {
+ property = prop;
+ }
+ rfa(animateStep);
+}
+
+function animateStep() {
+ if (currentOffset <= maxOffset) {
+ document.getElementById("child").style[property] = currentOffset + "px";
+ currentOffset += 10;
+ rfa(animateStep);
+ } else {
+ document.documentElement.removeAttribute("class");
+ }
+}
+
+function toAuto(prop) {
+ if (prop) {
+ property = prop;
+ }
+ rfa(setToAuto);
+}
+
+function setToAuto() {
+ document.getElementById("child").style[property] = "auto";
+ document.documentElement.removeAttribute("class");
+}
+
+function fromAuto(to, prop) {
+ maxOffset = to;
+ if (prop) {
+ property = prop;
+ }
+ rfa(setFromAuto);
+}
+
+function setFromAuto() {
+ document.getElementById("child").style[property] = maxOffset + "px";
+ document.documentElement.removeAttribute("class");
+}
+
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightA-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightA-bottomN.html
new file mode 100644
index 0000000000..d8c500293d
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightA-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(200, "bottom");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomA.html
new file mode 100644
index 0000000000..ba270ce844
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(200, "height");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomN.html
new file mode 100644
index 0000000000..c8355d8541
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topA-heightN-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(200, "bottom");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA-2.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA-2.html
new file mode 100644
index 0000000000..0979742676
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA-2.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(360);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA.html
new file mode 100644
index 0000000000..d4f5cd7d0b
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(200);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN-2.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN-2.html
new file mode 100644
index 0000000000..c6090e7f4d
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN-2.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="bottom: 20px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(340);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN.html
new file mode 100644
index 0000000000..daf37a46bd
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightA-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="bottom: 20px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(200);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightN-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightN-bottomA.html
new file mode 100644
index 0000000000..a417786c5f
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/fromauto-topN-heightN-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ fromAuto(200);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest.list b/layout/reftests/position-dynamic-changes/vertical/reftest.list
new file mode 100644
index 0000000000..5f888a3ad8
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest.list
@@ -0,0 +1,18 @@
+# This directory includes 7 different permutations of the same tests.
+# reftest_plain.list is the manifest file for tests without any border, margin
+# or padding applied to either the abs-pos element or the parent.
+# reftest_{prop}_{element}.list files are the manifest files for tests with the
+# CSS property {prop} applied to {element}. These files use the query string
+# on the test file and the reference file to ask the code in ../handleprop.js add
+# the corresponding CSS style.
+
+# Any changes to the contents of the following files needs to be reflected on
+# all of them.
+
+include reftest_plain.list
+include reftest_border_abspos.list
+include reftest_border_parent.list
+include reftest_margin_abspos.list
+include reftest_margin_parent.list
+include reftest_padding_abspos.list
+include reftest_padding_parent.list
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest.listbackup b/layout/reftests/position-dynamic-changes/vertical/reftest.listbackup
new file mode 100644
index 0000000000..86a90a0cdf
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest.listbackup
@@ -0,0 +1,12 @@
+== topN-heightA-bottomA.html topN-heightA-bottomA-ref.html
+== topN-heightA-bottomN.html topN-heightA-bottomN-ref.html
+== topA-heightN-bottomA.html topA-heightN-bottomA-ref.html
+== topN-heightN-bottomA.html topN-heightN-bottomA-ref.html
+== topA-heightN-bottomN.html topA-heightN-bottomN-ref.html
+== topA-heightA-bottomN.html topA-heightA-bottomN-ref.html
+== toauto-topN-heightA-bottomA.html toauto-topN-heightA-bottomA-ref.html
+== toauto-topN-heightA-bottomN.html toauto-topN-heightA-bottomN-ref.html
+== toauto-topA-heightN-bottomA.html toauto-topA-heightN-bottomA-ref.html
+== toauto-topN-heightN-bottomA.html toauto-topN-heightN-bottomA-ref.html
+== toauto-topA-heightN-bottomN.html toauto-topA-heightN-bottomN-ref.html
+== toauto-topA-heightA-bottomN.html toauto-topA-heightA-bottomN-ref.html
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_border_abspos.list b/layout/reftests/position-dynamic-changes/vertical/reftest_border_abspos.list
new file mode 100644
index 0000000000..cbd174f051
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_border_abspos.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html?border_abspos topN-heightA-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html?border_abspos topN-heightA-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html?border_abspos topA-heightN-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html?border_abspos topN-heightN-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html?border_abspos topA-heightN-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html?border_abspos topA-heightA-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html?border_abspos toauto-topN-heightA-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html?border_abspos toauto-topN-heightA-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html?border_abspos toauto-topA-heightN-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html?border_abspos toauto-topN-heightN-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html?border_abspos toauto-topA-heightN-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html?border_abspos toauto-topA-heightA-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html?border_abspos topN-heightA-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html?border_abspos topN-heightA-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html?border_abspos topA-heightN-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html?border_abspos topN-heightN-bottomA-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html?border_abspos topA-heightN-bottomN-ref.html?border_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html?border_abspos topA-heightA-bottomN-ref.html?border_abspos
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_border_parent.list b/layout/reftests/position-dynamic-changes/vertical/reftest_border_parent.list
new file mode 100644
index 0000000000..b4a74a16ef
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_border_parent.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html?border_parent topN-heightA-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html?border_parent topN-heightA-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html?border_parent topA-heightN-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html?border_parent topN-heightN-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html?border_parent topA-heightN-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html?border_parent topA-heightA-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html?border_parent toauto-topN-heightA-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html?border_parent toauto-topN-heightA-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html?border_parent toauto-topA-heightN-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html?border_parent toauto-topN-heightN-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html?border_parent toauto-topA-heightN-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html?border_parent toauto-topA-heightA-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html?border_parent topN-heightA-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html?border_parent topN-heightA-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html?border_parent topA-heightN-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html?border_parent topN-heightN-bottomA-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html?border_parent topA-heightN-bottomN-ref.html?border_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html?border_parent topA-heightA-bottomN-ref.html?border_parent
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_margin_abspos.list b/layout/reftests/position-dynamic-changes/vertical/reftest_margin_abspos.list
new file mode 100644
index 0000000000..139bf3f9ab
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_margin_abspos.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html?margin_abspos topN-heightA-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html?margin_abspos topN-heightA-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html?margin_abspos topA-heightN-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html?margin_abspos topN-heightN-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html?margin_abspos topA-heightN-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html?margin_abspos topA-heightA-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html?margin_abspos toauto-topN-heightA-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html?margin_abspos toauto-topN-heightA-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html?margin_abspos toauto-topA-heightN-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html?margin_abspos toauto-topN-heightN-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html?margin_abspos toauto-topA-heightN-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html?margin_abspos toauto-topA-heightA-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html?margin_abspos topN-heightA-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html?margin_abspos topN-heightA-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html?margin_abspos topA-heightN-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html?margin_abspos topN-heightN-bottomA-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html?margin_abspos topA-heightN-bottomN-ref.html?margin_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html?margin_abspos topA-heightA-bottomN-ref.html?margin_abspos
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_margin_parent.list b/layout/reftests/position-dynamic-changes/vertical/reftest_margin_parent.list
new file mode 100644
index 0000000000..0ac1395c43
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_margin_parent.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html?margin_parent topN-heightA-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html?margin_parent topN-heightA-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html?margin_parent topA-heightN-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html?margin_parent topN-heightN-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html?margin_parent topA-heightN-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html?margin_parent topA-heightA-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html?margin_parent toauto-topN-heightA-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html?margin_parent toauto-topN-heightA-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html?margin_parent toauto-topA-heightN-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html?margin_parent toauto-topN-heightN-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html?margin_parent toauto-topA-heightN-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html?margin_parent toauto-topA-heightA-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html?margin_parent topN-heightA-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html?margin_parent topN-heightA-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html?margin_parent topA-heightN-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html?margin_parent topN-heightN-bottomA-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html?margin_parent topA-heightN-bottomN-ref.html?margin_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html?margin_parent topA-heightA-bottomN-ref.html?margin_parent
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_padding_abspos.list b/layout/reftests/position-dynamic-changes/vertical/reftest_padding_abspos.list
new file mode 100644
index 0000000000..133d952931
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_padding_abspos.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html?padding_abspos topN-heightA-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html?padding_abspos topN-heightA-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html?padding_abspos topA-heightN-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html?padding_abspos topN-heightN-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html?padding_abspos topA-heightN-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html?padding_abspos topA-heightA-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html?padding_abspos toauto-topN-heightA-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html?padding_abspos toauto-topN-heightA-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html?padding_abspos toauto-topA-heightN-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html?padding_abspos toauto-topN-heightN-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html?padding_abspos toauto-topA-heightN-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html?padding_abspos toauto-topA-heightA-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html?padding_abspos topN-heightA-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html?padding_abspos topN-heightA-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html?padding_abspos topA-heightN-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html?padding_abspos topN-heightN-bottomA-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html?padding_abspos topA-heightN-bottomN-ref.html?padding_abspos
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html?padding_abspos topA-heightA-bottomN-ref.html?padding_abspos
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_padding_parent.list b/layout/reftests/position-dynamic-changes/vertical/reftest_padding_parent.list
new file mode 100644
index 0000000000..d62ec4e39b
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_padding_parent.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html?padding_parent topN-heightA-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html?padding_parent topN-heightA-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html?padding_parent topA-heightN-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html?padding_parent topN-heightN-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html?padding_parent topA-heightN-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html?padding_parent topA-heightA-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html?padding_parent toauto-topN-heightA-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html?padding_parent toauto-topN-heightA-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html?padding_parent toauto-topA-heightN-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html?padding_parent toauto-topN-heightN-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html?padding_parent toauto-topA-heightN-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html?padding_parent toauto-topA-heightA-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html?padding_parent topN-heightA-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html?padding_parent topN-heightA-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html?padding_parent topA-heightN-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html?padding_parent topN-heightN-bottomA-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html?padding_parent topA-heightN-bottomN-ref.html?padding_parent
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html?padding_parent topA-heightA-bottomN-ref.html?padding_parent
diff --git a/layout/reftests/position-dynamic-changes/vertical/reftest_plain.list b/layout/reftests/position-dynamic-changes/vertical/reftest_plain.list
new file mode 100644
index 0000000000..d7aaff396e
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/reftest_plain.list
@@ -0,0 +1,20 @@
+# Please see the comment at the beginning of reftest.list
+
+skip-if(ThreadSanitizer) fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomA.html topN-heightA-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightA-bottomN.html topN-heightA-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomA.html topA-heightN-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == topN-heightN-bottomA.html topN-heightN-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightN-bottomN.html topA-heightN-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == topA-heightA-bottomN.html topA-heightA-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomA.html toauto-topN-heightA-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightA-bottomN.html toauto-topN-heightA-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomA.html toauto-topA-heightN-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topN-heightN-bottomA.html toauto-topN-heightN-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightN-bottomN.html toauto-topA-heightN-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == toauto-topA-heightA-bottomN.html toauto-topA-heightA-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomA.html topN-heightA-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightA-bottomN.html topN-heightA-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomA.html topA-heightN-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topN-heightN-bottomA.html topN-heightN-bottomA-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightN-bottomN.html topA-heightN-bottomN-ref.html
+fuzzy-if(geckoview,0-2,0-1382) == fromauto-topA-heightA-bottomN.html topA-heightA-bottomN-ref.html
diff --git a/layout/reftests/position-dynamic-changes/vertical/style.css b/layout/reftests/position-dynamic-changes/vertical/style.css
new file mode 100644
index 0000000000..f546e6063b
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/style.css
@@ -0,0 +1,19 @@
+#parent {
+ position: relative;
+ width: 400px;
+ height: 400px;
+ background: red;
+ border: 0 solid black;
+}
+#child {
+ position: absolute;
+ width: 100px;
+ left: 100px;
+ background: blue;
+ border: 0 solid black;
+}
+.floatTop {
+ width: 10px;
+ height: 10px;
+ background: green;
+}
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN-ref.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN-ref.html
new file mode 100644
index 0000000000..77f3a35d6a
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN.html
new file mode 100644
index 0000000000..defcaaf36c
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightA-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="bottom: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ toAuto("bottom");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA-ref.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA-ref.html
new file mode 100644
index 0000000000..77f3a35d6a
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA.html
new file mode 100644
index 0000000000..713103f622
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ toAuto("height");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN-ref.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN-ref.html
new file mode 100644
index 0000000000..3ac9c1bbcf
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN.html
new file mode 100644
index 0000000000..6a7dfd263a
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topA-heightN-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px; bottom: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ toAuto("bottom");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA-ref.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA-ref.html
new file mode 100644
index 0000000000..77f3a35d6a
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA.html
new file mode 100644
index 0000000000..e590f8656a
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="top: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ toAuto("top");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN-ref.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN-ref.html
new file mode 100644
index 0000000000..dcd0e371de
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="bottom: 20px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN.html
new file mode 100644
index 0000000000..ad4e3e8473
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightA-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="top: 100px; bottom: 20px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ toAuto("top");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA-ref.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA-ref.html
new file mode 100644
index 0000000000..3ac9c1bbcf
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA.html
new file mode 100644
index 0000000000..56f16219e7
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/toauto-topN-heightN-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px; top: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ toAuto("top");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN-ref.html b/layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN-ref.html
new file mode 100644
index 0000000000..75f7f20153
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="bottom: 200px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN.html
new file mode 100644
index 0000000000..d7e854a88a
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topA-heightA-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="bottom: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ animate(100, 200, "bottom");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA-ref.html b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA-ref.html
new file mode 100644
index 0000000000..1513ea8e6e
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 200px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA.html
new file mode 100644
index 0000000000..38a506372b
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ animate(100, 200, "height");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN-ref.html b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN-ref.html
new file mode 100644
index 0000000000..054f968bc4
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px; bottom: 200px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN.html
new file mode 100644
index 0000000000..832d77a2a6
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topA-heightN-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px; bottom: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ animate(100, 200, "bottom");
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA-ref.html b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA-ref.html
new file mode 100644
index 0000000000..bcec5c9d6e
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="top: 200px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA.html
new file mode 100644
index 0000000000..ca943c2451
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="top: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ animate(100, 200);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN-ref.html b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN-ref.html
new file mode 100644
index 0000000000..13417a737b
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="top: 200px; bottom: 20px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN.html b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN.html
new file mode 100644
index 0000000000..2200c46183
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topN-heightA-bottomN.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="top: 100px; bottom: 20px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ animate(100, 200);
+ </script>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA-ref.html b/layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA-ref.html
new file mode 100644
index 0000000000..8e2ef7b2e0
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA-ref.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px; top: 200px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA.html b/layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA.html
new file mode 100644
index 0000000000..73ae72d582
--- /dev/null
+++ b/layout/reftests/position-dynamic-changes/vertical/topN-heightN-bottomA.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+ <head>
+ <link rel="stylesheet" type="text/css" href="style.css">
+ <script src="animate.js" type="text/javascript"></script>
+ <script src="../handleprop.js" type="text/javascript"></script>
+ </head>
+ <body>
+ <div id="parent">
+ <div id="child" style="height: 100px; top: 100px;">
+ <div class="floatTop"></div>
+ <div class="floatTop"></div>
+ </div>
+ </div>
+ <script>
+ animate(100, 200);
+ </script>
+ </body>
+</html>