Bug 1418867 - Crash test for the case where the parent element has no style data for pseudo. r?emilio draft
authorHiroyuki Ikezoe <hikezoe@mozilla.com>
Wed, 22 Nov 2017 12:20:15 +0900
changeset 701686 8fe9bb8bbdf5c68b979210d445ee5d918f90e2fc
parent 701685 6661b4e81ec5f7e093c73b6fdd4f34dee92f9eb3
child 741238 a43d18066e11d3345fcc76f9c06a66b1b59663dc
push id90239
push userhikezoe@mozilla.com
push dateWed, 22 Nov 2017 04:18:13 +0000
reviewersemilio
bugs1418867
milestone59.0a1
Bug 1418867 - Crash test for the case where the parent element has no style data for pseudo. r?emilio MozReview-Commit-ID: 977gqyZTob2
layout/style/crashtests/1418867.html
layout/style/crashtests/crashtests.list
new file mode 100644
--- /dev/null
+++ b/layout/style/crashtests/1418867.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+<style>
+@keyframes anim {
+  to { transform: rotate(360deg); }
+}
+.document-ready div::after {
+  display: none;
+}
+div::after {
+  content: "";
+}
+.animation::after {
+  animation: anim 1s infinite;
+}
+</style>
+<div id="target"></div>
+<script>
+window.addEventListener('load', () => {
+  target.classList.add('animation');
+  const psuedo = document.getAnimations()[0].effect.target;
+  target.classList.remove('animation');
+
+  psuedo.animate([ { transform: 'rotate(360deg)' } ], 1000);
+  requestAnimationFrame(() => {
+    document.documentElement.classList.add('document-ready');
+    requestAnimationFrame(() => {
+      document.documentElement.classList.remove('reftest-wait');
+    });
+  });
+});
+</script>
+</html>
--- a/layout/style/crashtests/crashtests.list
+++ b/layout/style/crashtests/crashtests.list
@@ -259,8 +259,9 @@ load 1410226-2.html
 load 1411143.html
 load 1411478.html
 load 1413288.html
 load 1413361.html
 load 1415663.html
 pref(dom.webcomponents.enabled,true) load 1415353.html
 load 1415021.html # This should have dom.webcomponents.enabled=true, but it leaks the world, see bug 1416296.
 load 1418059.html
+skip-if(!stylo) test-pref(dom.animations-api.core.enabled,true) load 1418867.html