| Index: third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/AnimationEffectTiming/delay.html
|
| diff --git a/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/AnimationEffectTiming/delay.html b/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/AnimationEffectTiming/delay.html
|
| index d6e1cd904543003a7bcf1e8eba32a95e39bd4257..1b34f7dbe761c72d70fd6d7498b6fd18e207ef2c 100644
|
| --- a/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/AnimationEffectTiming/delay.html
|
| +++ b/third_party/WebKit/LayoutTests/external/wpt/web-animations/interfaces/AnimationEffectTiming/delay.html
|
| @@ -12,6 +12,11 @@
|
| 'use strict';
|
|
|
| test(function(t) {
|
| + var anim = createDiv(t).animate(null);
|
| + assert_equals(anim.effect.timing.delay, 0);
|
| +}, 'Test default value');
|
| +
|
| +test(function(t) {
|
| var div = createDiv(t);
|
| var anim = div.animate({ opacity: [ 0, 1 ] }, 100);
|
| anim.effect.timing.delay = 100;
|
| @@ -57,5 +62,18 @@ test(function(t) {
|
| assert_equals(anim.effect.getComputedTiming().currentIteration, 0);
|
| }, 'Test finishing an animation using a large negative delay');
|
|
|
| +test(function(t) {
|
| + var div = createDiv(t);
|
| + var anim = div.animate(null);
|
| + for (let invalid of [NaN, Infinity]) {
|
| + assert_throws({ name: 'TypeError' }, function() {
|
| + anim.effect.timing.delay = invalid;
|
| + }, 'setting ' + invalid);
|
| + assert_throws({ name: 'TypeError' }, function() {
|
| + div.animate({}, { delay: invalid });
|
| + }, 'animate() with ' + invalid);
|
| + }
|
| +}, 'Setting invalid values should throw TypeError');
|
| +
|
| </script>
|
| </body>
|
|
|