Bug 1335876 - Part 4. Reftest. draft
authorcku <cku@mozilla.com>
Fri, 03 Feb 2017 00:57:10 +0800
changeset 479445 6b4d5d762880b5f917533311e082a0236f0819d9
parent 479444 ad73100be814036bada79a13fb9700dac2d7c8fd
child 544691 03959dcbf0c78437991223beaa029ec9eec88303
push id44261
push userbmo:cku@mozilla.com
push dateMon, 06 Feb 2017 18:35:30 +0000
bugs1335876
milestone54.0a1
Bug 1335876 - Part 4. Reftest. MozReview-Commit-ID: HMrMTTxgga4
layout/reftests/transform/pass.svg
layout/reftests/transform/reftest.list
layout/reftests/transform/transform-box-svg-3a.svg
new file mode 100644
--- /dev/null
+++ b/layout/reftests/transform/pass.svg
@@ -0,0 +1,8 @@
+<!--
+     Any copyright is dedicated to the Public Domain.
+     http://creativecommons.org/publicdomain/zero/1.0/
+-->
+<svg xmlns="http://www.w3.org/2000/svg" version="1.1">
+  <title>Testcase reference file for generic pass condition</title>
+  <rect width="100%" height="100%" fill="lime"/>
+</svg>
--- a/layout/reftests/transform/reftest.list
+++ b/layout/reftests/transform/reftest.list
@@ -124,16 +124,17 @@ fuzzy-if(skiaContent,2,5) == stresstest-
 == table-2a.html table-2-ref.html
 == table-2b.html table-2-ref.html
 # Bug 722463
 == inline-1a.html inline-1-ref.html
 pref(svg.transform-box.enabled,true) == transform-box-svg-1a.svg transform-box-svg-1-ref.svg
 pref(svg.transform-box.enabled,true) == transform-box-svg-1b.svg transform-box-svg-1-ref.svg
 pref(svg.transform-box.enabled,true) == transform-box-svg-2a.svg transform-box-svg-2-ref.svg
 pref(svg.transform-box.enabled,true) == transform-box-svg-2b.svg transform-box-svg-2-ref.svg
+pref(svg.transform-box.enabled,true) == transform-box-svg-3a.svg pass.svg
 == transform-origin-svg-1a.svg transform-origin-svg-1-ref.svg
 == transform-origin-svg-1b.svg transform-origin-svg-1-ref.svg
 == transform-origin-svg-2a.svg transform-origin-svg-2-ref.svg
 == transform-origin-svg-2b.svg transform-origin-svg-2-ref.svg
 # Bug 1122526
 == animate-layer-scale-inherit-1.html animate-layer-scale-inherit-1-ref.html
 == animate-layer-scale-inherit-2.html animate-layer-scale-inherit-2-ref.html
 == animate-layer-scale-inherit-3.html animate-layer-scale-inherit-1-ref.html
new file mode 100644
--- /dev/null
+++ b/layout/reftests/transform/transform-box-svg-3a.svg
@@ -0,0 +1,64 @@
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 100 100" preserveAspectRatio="none">
+  <style>
+    /* <![CDATA[ */
+    .ref {
+      fill: lime;
+    }
+    .test {
+      fill: red;
+    }
+    /* ]]> */
+  </style>
+  <rect width="100%" height="100%" fill="lime"/>
+  <!-- all rect.test rects should be covered by the corresponded rest.ref rect-->
+  <!-- 1st row: transform-box only. -->
+  <rect class="test"
+        style="transform-box: view-box"
+        x="11" y="11" width="8" height="8"/>
+  <rect class="ref"
+        x="10" y="10" width="10" height="10"/>
+  <rect class="test"
+        style="transform-box: fill-box"
+        x="26" y="11" width="8" height="8"/>
+  <rect class="ref"
+        x="25" y="10" width="10" height="10"/>
+  <rect class="test"
+        style="transform-box: border-box"
+        x="41" y="11" width="8" height="8"/>
+  <rect class="ref"
+        x="40" y="10" width="10" height="10"/>
+
+  <!-- 2nd row: transform-box plus transform-origin. -->
+  <rect class="test"
+        style="transform-box: view-box; tansform-origin: 40% 60%"
+        x="11" y="26" width="8" height="8"/>
+  <rect class="ref"
+        x="10" y="25" width="10" height="10"/>
+  <rect class="test"
+        style="transform-box: fill-box; tansform-origin: 20px 10px"
+        x="26" y="26" width="8" height="8"/>
+  <rect class="ref"
+        x="25" y="25" width="10" height="10"/>
+  <rect class="test"
+        style="transform-box: border-box; tansform-origin: 40% 60%"
+        x="41" y="26" width="8" height="8"/>
+  <rect class="ref"
+        x="40" y="25" width="10" height="10"/>
+
+  <!-- 2nd row: transform-box, transform-origin and transform. -->
+  <rect class="test"
+        style="transform-box: view-box; tansform-origin: 0% 0%; transform: scale(1);"
+        x="11" y="46" width="8" height="8"/>
+  <rect class="ref"
+        x="10" y="45" width="10" height="10"/>
+  <rect class="test"
+        style="transform-box: fill-box; transform-origin:50% 50%; transform:rotate(45deg);"
+        x="26" y="46" width="4" height="4"/>
+  <rect class="ref"
+        x="25" y="45" width="10" height="10"/>
+  <rect class="test"
+        style="transform-box: border-box; tansform-origin: 100% 100% transform: scale(1);"
+        x="41" y="46" width="8" height="8"/>
+  <rect class="ref"
+        x="40" y="45" width="10" height="10"/>
+</svg>
\ No newline at end of file