Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/web-animations-api/animation-source-becomes-longer.html |
| diff --git a/third_party/WebKit/LayoutTests/web-animations-api/animation-source-becomes-longer.html b/third_party/WebKit/LayoutTests/web-animations-api/animation-source-becomes-longer.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..67281c71f85c7a6123ad35f9f4c59e17e8baba43 |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/web-animations-api/animation-source-becomes-longer.html |
| @@ -0,0 +1,23 @@ |
| +<!DOCTYPE html> |
| +<meta charset=utf-8> |
| +<title>Test that extending effect should not cause a change in start time</title> |
| +<link rel="https://w3c.github.io/web-animations/#the-animation-interface"> |
| +<script src="../resources/testharness.js"></script> |
| +<script src="../resources/testharnessreport.js"></script> |
| +<script src="../imported/wpt/web-animations/testcommon.js"></script> |
| +<script> |
| +test(function() { |
| + document.timeline.playbackRate = 0; |
| + document.timeline.currentTime = 0; |
| + var animation = document.documentElement.animate([], 1000); |
| + animation.startTime = -1000; |
| + |
| + assert_times_equal(animation.currentTime, 1000); |
| + |
| + animation.effect.timing.duration = 1500; |
|
alancutter (OOO until 2018)
2016/07/12 03:39:10
The effect on the Animation interface is readonly.
|
| + document.timeline.currentTime = 2000; |
| + |
| + assert_times_equal(animation.startTime, -1000); |
| + assert_times_equal(animation.currentTime, 1500); |
| +}, 'Extending effect should not cause a change in start time.'); |
| +</script> |