Bug 1371450 - Crash test. r?emilio draft
authorHiroyuki Ikezoe <hikezoe@mozilla.com>
Sat, 15 Jul 2017 13:16:15 +0900
changeset 609306 5735b1e3465063d79cf4c232e1e0a15a7391dff0
parent 609305 5a7c8b2b6f82639cbffea19c53a0917444234974
child 637542 de77b83d5dcea38633e565422d0185b7f0bddbf6
push id68545
push userhikezoe@mozilla.com
push dateSat, 15 Jul 2017 04:17:02 +0000
reviewersemilio
bugs1371450
milestone56.0a1
Bug 1371450 - Crash test. r?emilio The crash test causes a panic in Servo_ResolveStyle on debug build without this patch series. The reason why we send mouse move event twice is that one for E10S and the other one is for non-E10S. It seems to be caused by being requestIdleCallback processed on different timing. MozReview-Commit-ID: 7cBmwhE9HDk
layout/style/crashtests/1371450-1.html
layout/style/crashtests/crashtests.list
new file mode 100644
--- /dev/null
+++ b/layout/style/crashtests/1371450-1.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+<title></title>
+<style>
+@keyframes anim {
+  to { transform: rotate(360deg); }
+}
+#animation {
+  animation: anim 3s infinite;
+}
+.red {
+  color: red;
+}
+</style>
+<div><span id="target">text</span></div>
+<div id="animation">animation</div>
+<script>
+window.addEventListener('load', () => {
+  var target = document.getElementById('target');
+  target.classList.add('red');
+  requestIdleCallback(() => {
+    target.classList.remove('red');
+    SpecialPowers.getDOMWindowUtils(window)
+                 .sendMouseEvent("mousemove", 100, 100, 1,
+                                 0, 1, 0);
+    requestIdleCallback(() => {
+      document.documentElement.classList.remove("reftest-wait");
+    });
+  });
+  SpecialPowers.getDOMWindowUtils(window)
+               .sendMouseEvent("mousemove", 100, 100, 1,
+                               0, 1, 0);
+});
+</script>
--- a/layout/style/crashtests/crashtests.list
+++ b/layout/style/crashtests/crashtests.list
@@ -166,16 +166,17 @@ HTTP load 1320423-1.html
 load 1321357-1.html
 load 1328535-1.html
 load 1331272.html
 HTTP load 1333001-1.html
 pref(dom.animations-api.core.enabled,true) load 1340344.html
 load 1342316-1.html
 load 1356601-1.html
 load 1370793-1.xhtml
+load 1371450-1.html
 load 1374175-1.html
 load content-only-on-link-before.html
 load content-only-on-visited-before.html
 load 1375812-1.html
 load 1377053-1.html
 load 1377256-1.html
 load 1378814.html
 load 1380800.html