Index: third_party/WebKit/LayoutTests/animations/custom-properties/registered-neutral-keyframe.html |
diff --git a/third_party/WebKit/LayoutTests/animations/custom-properties/registered-neutral-keyframe.html b/third_party/WebKit/LayoutTests/animations/custom-properties/registered-neutral-keyframe.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..37c12c5b7a102f200f350519cb7a0888b4a005fd |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/animations/custom-properties/registered-neutral-keyframe.html |
@@ -0,0 +1,27 @@ |
+<!DOCTYPE html> |
+<script src="../../resources/testharness.js"></script> |
+<script src="../../resources/testharnessreport.js"></script> |
+<style> |
+@keyframes test { |
+ to { --x: to; } |
+} |
+#target { |
+ --x: underlying; |
+ animation: test 1s; |
+} |
+</style> |
+<div id="target"></div> |
+<script> |
+CSS.registerProperty({ |
+ name: '--x', |
+ syntax: '*', |
+}); |
+ |
+test(() => { |
+ target.style.animationDelay = '-0.25s'; |
+ assert_equals(getComputedStyle(target).getPropertyValue('--x'), ' underlying', 'at 25%'); |
+ |
+ target.style.animationDelay = '-0.75s'; |
+ assert_equals(getComputedStyle(target).getPropertyValue('--x'), ' to', 'at 25%'); |
+}, 'CSS Animations neutral keyframes on registered custom properties should produce the underlying value'); |
+</script> |