Bug 1394302 - stylo: Add mochitest; r=birtles
authorManish Goregaokar <manishearth@gmail.com>
Thu, 31 Aug 2017 17:26:51 -0700
changeset 428548 e36fd3453c2826871da5412fb102234d19ece473
parent 428547 3be607112552ab93e30c07e6f46af3eec0ea6536
child 428549 925734099cb949213a66399c1d1477828caeb465
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbirtles
bugs1394302
milestone57.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 1394302 - stylo: Add mochitest; r=birtles MozReview-Commit-ID: DJ3zFqqMNXk
layout/style/test/mochitest.ini
layout/style/test/test_bug1394302.html
--- a/layout/style/test/mochitest.ini
+++ b/layout/style/test/mochitest.ini
@@ -159,16 +159,18 @@ support-files = file_bug1089417_iframe.h
 [test_bug1203766.html]
 [test_bug1232829.html]
 [test_bug1292447.html]
 [test_bug1371488.html]
 [test_bug1375944.html]
 support-files = file_bug1375944.html Ahem.ttf
 [test_bug1382568.html]
 support-files = bug1382568-iframe.html
+[test_bug1394302.html]
+skip-if = !stylo # This is a stylo test; gecko isn't deterministic here
 [test_cascade.html]
 [test_ch_ex_no_infloops.html]
 [test_change_hint_optimizations.html]
 [test_clip-path_polygon.html]
 [test_color_rounding.html]
 [test_compute_data_with_start_struct.html]
 skip-if = toolkit == 'android'
 [test_computed_style.html]
new file mode 100644
--- /dev/null
+++ b/layout/style/test/test_bug1394302.html
@@ -0,0 +1,32 @@
+<!DOCTYPE HTML>
+<html>
+<!--
+https://bugzilla.mozilla.org/show_bug.cgi?id=1394302
+-->
+<head>
+  <title>Test for Bug 1394302</title>
+  <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
+  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
+    <style>
+    #inner {
+      animation: setFontSize 0s forwards;
+    }
+    @keyframes setFontSize {
+      to { font-size: calc(110% + 0.1em); }
+    }
+    </style>
+</head>
+<body>
+<div id=outer>
+  <div id=inner></div>
+</div>
+<script>
+var outer = document.getElementById("outer");
+outer.style.fontSize = '10px';
+is(getComputedStyle(inner).fontSize, "12px");
+
+outer.style.fontSize = '20px';
+is(getComputedStyle(inner).fontSize, "24px");
+</script>
+</body>
+</html>