From 43a97878ce14b72f0981164f87f2e35e14151312 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 11:22:09 +0200 Subject: Adding upstream version 110.0.1. Signed-off-by: Daniel Baumann --- .../tests/scroll-animations/css/support/testcommon.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 testing/web-platform/tests/scroll-animations/css/support/testcommon.js (limited to 'testing/web-platform/tests/scroll-animations/css/support') diff --git a/testing/web-platform/tests/scroll-animations/css/support/testcommon.js b/testing/web-platform/tests/scroll-animations/css/support/testcommon.js new file mode 100644 index 0000000000..66bc27bb10 --- /dev/null +++ b/testing/web-platform/tests/scroll-animations/css/support/testcommon.js @@ -0,0 +1,19 @@ +'use strict'; + +/** + * Returns a Promise that is resolved after a CSS scroll timeline is created (as + * the result of a style change) and a snapshot has been taken, so that the + * animation style is correctly reflected by getComputedStyle(). + * Technically, this only takes a full frame update. We implement this as two + * requestAnimationFrame callbacks because the result will be available at the + * beginning of the second frame. + */ +async function waitForCSSScrollTimelineStyle() { + await waitForNextFrame(); + await waitForNextFrame(); +} + +function assert_implements_animation_timeline() { + assert_implements(CSS.supports('animation-timeline:foo'), + 'animation-timeline not supported'); +} -- cgit v1.2.3