Bug 1368113 - Part 1: Test for restyling ::placeholder. r=bz
authorCameron McCormack <cam@mcc.id.au>
Sat, 10 Jun 2017 11:25:50 +0800
changeset 411481 9817633686c2bda12bffe8b306184322280a46ae
parent 411480 145daf186ca7790ffbeb88b8dea1f8e22e8bf4db
child 411482 129c04db249edf92fb1ab2dbfc283ad84cd530b9
push id7391
push usermtabara@mozilla.com
push dateMon, 12 Jun 2017 13:08:53 +0000
treeherdermozilla-beta@2191d7f87e2e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz
bugs1368113
milestone55.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1368113 - Part 1: Test for restyling ::placeholder. r=bz MozReview-Commit-ID: JDj1SZCrKmM
layout/reftests/bugs/1368113-1-ref.html
layout/reftests/bugs/1368113-1.html
layout/reftests/bugs/reftest.list
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1368113-1-ref.html
@@ -0,0 +1,5 @@
+<!DOCTYPE html>
+<style>
+  input::placeholder { color: green; }
+</style>
+<input type="number" placeholder="This should be green">
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1368113-1.html
@@ -0,0 +1,13 @@
+<!DOCTYPE html>
+<style>
+  input::placeholder { color: red; }
+  input.green::placeholder { color: green; }
+</style>
+<input type="number" placeholder="This should be green">
+<script>
+  var i = document.querySelector("input");
+  var s = getComputedStyle(i, "::placeholder");
+  // Make sure we've computed the old color.
+  var oldColor = s.color;
+  i.className = "green";
+</script>
--- a/layout/reftests/bugs/reftest.list
+++ b/layout/reftests/bugs/reftest.list
@@ -2003,11 +2003,12 @@ fails-if(styloVsGecko) == 1322512-1.html
 == 1364280-2b.html 1364280-2-ref.html
 == 1364280-2c.html 1364280-2-ref.html
 == 1364335.html 1364335-ref.html
 == 1364360-1.html 1364360-1-ref.html
 == 1365159-1.html 1365159-1-ref.html
 fails-if(!stylo||styloVsGecko) == 1365162-1.html 1365162-1-ref.html
 == 1366144.html 1366144-ref.html
 == 1367592-1.html 1367592-1-ref.html
+fails-if(!stylo) == 1368113-1.html 1368113-1-ref.html
 == 1369584-1a.html 1369584-1-ref.html
 == 1369584-1b.html 1369584-1-ref.html
 == 1369954-1.xhtml 1369954-1-ref.xhtml