Bug 1375513 Part 2 - Add a reftest for testing non-chrome XBL bindings with stylesheets. draft
authorTing-Yu Lin <tlin@mozilla.com>
Tue, 27 Jun 2017 22:24:59 -0700
changeset 601603 d5fbbd292dd129c22aee7ae4de005cae2f1fb77d
parent 601602 6ca55ac3df2a178d02c49c91b01fa3aa5474cd2f
child 635329 88045a10be26676fa933e8a3dadfdac0c47f25cb
push id66136
push userbmo:tlin@mozilla.com
push dateWed, 28 Jun 2017 22:59:51 +0000
bugs1375513, 1372876
milestone56.0a1
Bug 1375513 Part 2 - Add a reftest for testing non-chrome XBL bindings with stylesheets. This reftest can also catch bug 1372876 because it has pseudo element rules like ::-moz-range-progress in the XBL stylesheet. MozReview-Commit-ID: LUicjTRzMKt
layout/reftests/bugs/1375513-ref.html
layout/reftests/bugs/1375513.css
layout/reftests/bugs/1375513.html
layout/reftests/bugs/1375513.xml
layout/reftests/bugs/reftest.list
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1375513-ref.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html>
+  <head>
+    <title>Reference for bug 1375513</title>
+    <style type="text/css">
+    input[type=range] {
+      width: 200px;
+      height: 20px;
+      margin: 0;
+      padding: 0;
+      background-color: blue;
+    }
+
+    input[type=range]::-moz-range-progress {
+      height: 10px;
+      background-color: lime;
+    }
+
+    input[type=range]::-moz-range-track,
+    input[type=range]::-moz-range-thumb {
+      visibility: hidden;
+    }
+    </style>
+  </head>
+  <body>
+    <input type="range">
+  </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1375513.css
@@ -0,0 +1,17 @@
+input[type=range] {
+  width: 200px;
+  height: 20px;
+  margin: 0;
+  padding: 0;
+  background-color: blue;
+}
+
+input[type=range]::-moz-range-progress {
+  height: 10px;
+  background-color: lime;
+}
+
+input[type=range]::-moz-range-track,
+input[type=range]::-moz-range-thumb {
+  visibility: hidden;
+}
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1375513.html
@@ -0,0 +1,14 @@
+<!DOCTYPE html>
+<html>
+  <head>
+    <title>Test for bug 1375513</title>
+    <style type="text/css">
+    #input {
+      -moz-binding: url(1375513.xml#createInputRange);
+    }
+    </style>
+  </head>
+  <body>
+    <div id="input"></div>
+  </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1375513.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0"?>
+<bindings xmlns="http://www.mozilla.org/xbl"
+          xmlns:html="http://www.w3.org/1999/xhtml">
+  <binding id="createInputRange">
+    <resources>
+      <stylesheet src="1375513.css"/>
+    </resources>
+    <content><html:input type="range"/></content>
+  </binding>
+</bindings>
--- a/layout/reftests/bugs/reftest.list
+++ b/layout/reftests/bugs/reftest.list
@@ -2023,9 +2023,10 @@ fails-if(!stylo||styloVsGecko) == 136516
 == 1375315-6.html 1375315-6-ref.html
 == 1375315-7.html 1375315-7-ref.html
 == 1375315-8.html 1375315-8-ref.html
 == 1375315-9.html 1375315-9-ref.html
 == 1375315-10.html 1375315-10-ref.html
 == 1375315-11.html 1375315-11-ref.html
 == 1375315-12.html 1375315-12-ref.html
 == 1374062.html 1374062-ref.html
+== 1375513.html 1375513-ref.html
 == 1375674.html 1375674-ref.html