--- a/testing/web-platform/meta/MANIFEST.json
+++ b/testing/web-platform/meta/MANIFEST.json
@@ -585882,57 +585882,57 @@
"b23b76881f4d38c07710d0e59c1f6c8569de9060",
"testharness"
],
"web-animations/interfaces/Animation/startTime.html": [
"177a2f3e9dd366bfe4661c160cc23b73c27dec20",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/delay.html": [
- "ab9541da01fbfa0f832e575f975eb53f257b7660",
+ "e2b0cf3709d9b886f058a13d2a8fa467ab7fd1b4",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/direction.html": [
- "48eb372769ab550eb1a8b0478cdec922fef1cc69",
+ "ae9a1a3b2a5ae8dde6c0d2a7f2acad0fa93d6d5e",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/duration.html": [
- "75a06ca5a7ed464b76c2ae681b27f610fc4cc326",
+ "66281c3eea0d8a82e9cbc572b91f3ca9524eb0cd",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/easing.html": [
- "99001d99381a682a0eff8d5179322b58c288847c",
+ "26bc80cba1202beeb4d19115fcea0838a104ae9a",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/endDelay.html": [
- "7a0f6af148117424219e6b3fb981f4a6a48e5c5f",
+ "f3504241c25f53e6daa10ec12a5d8cc20d425b2b",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/fill.html": [
- "8a42e5fb0ffe5e4f90afb10fe0e15f46fff6f897",
+ "c0237dd37bd3e56e32bd3e027c5f9357081cfef0",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/getAnimations.html": [
"e0ad6da869693c4e4b57aa2e5e3cb4ec557c7bc8",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/getComputedStyle.html": [
"201bac6d13f4f8ed556fe63df214d6d565ba94b7",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/idlharness.html": [
"a4e72d3ebf93a0bb6934f887c3da250a2ab67b63",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/iterationStart.html": [
- "9c848de13c6ba0471566f20f5f3ec3118aa24e35",
+ "c6e3e9689f2c04a00567b144a9bfa329d4e522c8",
"testharness"
],
"web-animations/interfaces/AnimationEffectTiming/iterations.html": [
- "5f98e713437acf46726bb2364c83f20549cc56d3",
+ "e906c84dc4774846387eb9ea89d6707cee84dccb",
"testharness"
],
"web-animations/interfaces/AnimationPlaybackEvent/constructor.html": [
"1bc5f4dda96078a08a4b06ab0f6bf7b10e0acce3",
"testharness"
],
"web-animations/interfaces/AnimationPlaybackEvent/idlharness.html": [
"37bd201a374913d0cd580b89b07688b5b655776d",
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/delay.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/delay.html
@@ -8,71 +8,71 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.delay, 0);
-}, 'Test default value');
+}, 'Has the default value 0');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 100);
anim.effect.timing.delay = 100;
assert_equals(anim.effect.timing.delay, 100, 'set delay 100');
assert_equals(anim.effect.getComputedTiming().delay, 100,
'getComputedTiming() after set delay 100');
-}, 'set delay 100');
+}, 'Can be set to a positive number');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 100);
anim.effect.timing.delay = -100;
assert_equals(anim.effect.timing.delay, -100, 'set delay -100');
assert_equals(anim.effect.getComputedTiming().delay, -100,
'getComputedTiming() after set delay -100');
-}, 'set delay -100');
+}, 'Can be set to a negative number');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 100);
anim.effect.timing.delay = 100;
assert_equals(anim.effect.getComputedTiming().progress, null);
assert_equals(anim.effect.getComputedTiming().currentIteration, null);
-}, 'Test adding a positive delay to an animation without a backwards fill ' +
- 'makes it no longer active');
+}, 'Can set a positive delay on an animation without a backwards fill to'
+ + ' make it no longer active');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ fill: 'both',
duration: 100 });
anim.effect.timing.delay = -50;
assert_equals(anim.effect.getComputedTiming().progress, 0.5);
-}, 'Test seeking an animation by setting a negative delay');
+}, 'Can set a negative delay to seek into the active interval');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ fill: 'both',
duration: 100 });
anim.effect.timing.delay = -100;
assert_equals(anim.effect.getComputedTiming().progress, 1);
assert_equals(anim.effect.getComputedTiming().currentIteration, 0);
-}, 'Test finishing an animation using a large negative delay');
+}, 'Can set a large negative delay to finishing an animation');
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');
+}, 'Throws when setting invalid values');
</script>
</body>
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/direction.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/direction.html
@@ -8,24 +8,24 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.direction, 'normal');
-}, 'Test default value');
+}, 'Has the default value \'normal\'');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
var directions = ['normal', 'reverse', 'alternate', 'alternate-reverse'];
directions.forEach(function(direction) {
anim.effect.timing.direction = direction;
assert_equals(anim.effect.timing.direction, direction,
'set direction to ' + direction);
});
-}, 'set direction to a valid keyword');
+}, 'Can be set to each of the possible keywords');
</script>
</body>
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/duration.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/duration.html
@@ -8,149 +8,151 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.duration, 'auto');
-}, 'Test default value');
+}, 'Has the default value \'auto\'');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.duration = 123.45;
assert_times_equal(anim.effect.timing.duration, 123.45,
'set duration 123.45');
assert_times_equal(anim.effect.getComputedTiming().duration, 123.45,
'getComputedTiming() after set duration 123.45');
-}, 'set duration 123.45');
+}, 'Can be set to a double value');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.duration = 'auto';
assert_equals(anim.effect.timing.duration, 'auto', 'set duration \'auto\'');
assert_equals(anim.effect.getComputedTiming().duration, 0,
'getComputedTiming() after set duration \'auto\'');
-}, 'set duration auto');
+}, 'Can be set to the string \'auto\'');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, { duration: 'auto' });
assert_equals(anim.effect.timing.duration, 'auto', 'set duration \'auto\'');
assert_equals(anim.effect.getComputedTiming().duration, 0,
'getComputedTiming() after set duration \'auto\'');
-}, 'set auto duration in animate as object');
+}, 'Can be set to \'auto\' using a dictionary object');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.duration = Infinity;
assert_equals(anim.effect.timing.duration, Infinity, 'set duration Infinity');
assert_equals(anim.effect.getComputedTiming().duration, Infinity,
'getComputedTiming() after set duration Infinity');
-}, 'set duration Infinity');
+}, 'Can be set to Infinity');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, -1);
});
-}, 'set negative duration in animate using a duration parameter');
+}, 'animate() throws when passed a negative number');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, -Infinity);
});
-}, 'set negative Infinity duration in animate using a duration parameter');
+}, 'animate() throws when passed negative Infinity');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, NaN);
});
-}, 'set NaN duration in animate using a duration parameter');
+}, 'animate() throws when passed a NaN value');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, { duration: -1 });
});
-}, 'set negative duration in animate using an options object');
+}, 'animate() throws when passed a negative number using a dictionary object');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, { duration: -Infinity });
});
-}, 'set negative Infinity duration in animate using an options object');
+}, 'animate() throws when passed negative Infinity using a dictionary object');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, { duration: NaN });
});
-}, 'set NaN duration in animate using an options object');
+}, 'animate() throws when passed a NaN value using a dictionary object');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, { duration: 'abc' });
});
-}, 'set abc string duration in animate using an options object');
+}, 'animate() throws when passed a string other than \'auto\' using a'
+ + ' dictionary object');
test(function(t) {
var div = createDiv(t);
assert_throws({ name: 'TypeError' }, function() {
div.animate({ opacity: [ 0, 1 ] }, { duration: '100' });
});
-}, 'set 100 string duration in animate using an options object');
+}, 'animate() throws when passed a string containing a number using a'
+ + ' dictionary object');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.duration = -1;
});
-}, 'set negative duration');
+}, 'Throws when setting a negative number');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.duration = -Infinity;
});
-}, 'set negative Infinity duration');
+}, 'Throws when setting negative infinity');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.duration = NaN;
});
-}, 'set NaN duration');
+}, 'Throws when setting a NaN value');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.duration = 'abc';
});
-}, 'set duration abc');
+}, 'Throws when setting a string other than \'auto\'');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.duration = '100';
});
-}, 'set duration string 100');
+}, 'Throws when setting a string containing a number');
promise_test(function(t) {
var anim = createDiv(t).animate(null, 100 * MS_PER_SEC);
return anim.ready.then(function() {
var originalStartTime = anim.startTime;
var originalCurrentTime = anim.currentTime;
assert_equals(anim.effect.getComputedTiming().duration, 100 * MS_PER_SEC,
'Initial duration should be as set on KeyframeEffect');
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/easing.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/easing.html
@@ -9,17 +9,17 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.easing, 'linear');
-}, 'Test default value');
+}, 'Has the default value \'linear\'');
function assert_progress(animation, currentTime, easingFunction) {
animation.currentTime = currentTime;
var portion = currentTime / animation.effect.timing.duration;
assert_approx_equals(animation.effect.getComputedTiming().progress,
easingFunction(portion),
0.01,
'The progress of the animation should be approximately ' +
@@ -48,17 +48,17 @@ gEasingTests.forEach(function(options) {
gInvalidEasings.forEach(function(invalidEasing) {
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 100 * MS_PER_SEC);
assert_throws({ name: 'TypeError' },
function() {
anim.effect.timing.easing = invalidEasing;
});
- }, 'Invalid effect easing value test: \'' + invalidEasing + '\'');
+ }, 'Throws on invalid easing: \'' + invalidEasing + '\'');
});
gRoundtripEasings.forEach(easing => {
test(function(t) {
const anim = createDiv(t).animate(null);
anim.effect.timing.easing = easing;
assert_equals(anim.effect.timing.easing, easing);
}, `Canonical easing '${easing}' is returned as set`);
@@ -85,12 +85,12 @@ test(function(t) {
anim.effect.timing.easing = 'steps(2, start)';
assert_equals(anim.effect.getComputedTiming().progress, 1,
'easing replace to steps(2, start) at active phase');
anim.currentTime = delay + 1500 * MS_PER_SEC;
anim.effect.timing.easing = 'steps(2, end)';
assert_equals(anim.effect.getComputedTiming().progress, 1,
'easing replace to steps(2, end) again at after phase');
-}, 'Change the easing while the animation is running');
+}, 'Allows the easing to be changed while the animation is in progress');
</script>
</body>
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/endDelay.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/endDelay.html
@@ -9,68 +9,69 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.endDelay, 0);
-}, 'Test default value');
+}, 'Has the default value 0');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.endDelay = 123.45;
assert_times_equal(anim.effect.timing.endDelay, 123.45,
'set endDelay 123.45');
assert_times_equal(anim.effect.getComputedTiming().endDelay, 123.45,
'getComputedTiming() after set endDelay 123.45');
-}, 'set endDelay 123.45');
+}, 'Can be set to a positive number');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.endDelay = -1000;
assert_equals(anim.effect.timing.endDelay, -1000, 'set endDelay -1000');
assert_equals(anim.effect.getComputedTiming().endDelay, -1000,
'getComputedTiming() after set endDelay -1000');
-}, 'set endDelay -1000');
+}, 'Can be set to a negative number');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({name: "TypeError"}, function() {
anim.effect.timing.endDelay = Infinity;
}, 'we can not assign Infinity to timing.endDelay');
-}, 'set endDelay Infinity');
+}, 'Throws when setting infinity');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({name: "TypeError"}, function() {
anim.effect.timing.endDelay = -Infinity;
}, 'we can not assign negative Infinity to timing.endDelay');
-}, 'set endDelay negative Infinity');
+}, 'Throws when setting negative infinity');
async_test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ duration: 100000, endDelay: 50000 });
anim.onfinish = t.step_func(function(event) {
- assert_unreached('onfinish event should not be fired');
+ assert_unreached('finish event should not be fired');
});
anim.ready.then(function() {
anim.currentTime = 100000;
return waitForAnimationFrames(2);
}).then(t.step_func(function() {
t.done();
}));
-}, 'onfinish event is not fired duration endDelay');
+}, 'finish event is not fired at the end of the active interval when the'
+ + ' endDelay has not expired');
async_test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ duration: 100000, endDelay: 30000 });
anim.ready.then(function() {
anim.currentTime = 110000; // during endDelay
anim.onfinish = t.step_func(function(event) {
@@ -78,12 +79,12 @@ async_test(function(t) {
});
return waitForAnimationFrames(2);
}).then(t.step_func(function() {
anim.onfinish = t.step_func(function(event) {
t.done();
});
anim.currentTime = 130000; // after endTime
}));
-}, 'onfinish event is fired currentTime is after endTime');
+}, 'finish event is fired after the endDelay has expired');
</script>
</body>
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/fill.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/fill.html
@@ -8,22 +8,23 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.fill, 'auto');
-}, 'Test default value');
+}, 'Has the default value \'auto\'');
["none", "forwards", "backwards", "both", ].forEach(function(fill){
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 100);
anim.effect.timing.fill = fill;
assert_equals(anim.effect.timing.fill, fill, 'set fill ' + fill);
- assert_equals(anim.effect.getComputedTiming().fill, fill, 'getComputedTiming() after set fill ' + fill);
- }, 'set fill ' + fill);
+ assert_equals(anim.effect.getComputedTiming().fill, fill,
+ 'getComputedTiming() after set fill ' + fill);
+ }, 'Can set fill to ' + fill);
});
</script>
</body>
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/iterationStart.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/iterationStart.html
@@ -9,68 +9,65 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.iterationStart, 0);
-}, 'Test default value');
+}, 'Has the default value 0');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ iterationStart: 0.2,
iterations: 1,
fill: 'both',
duration: 100,
delay: 1 });
anim.effect.timing.iterationStart = 2.5;
assert_equals(anim.effect.getComputedTiming().progress, 0.5);
assert_equals(anim.effect.getComputedTiming().currentIteration, 2);
-}, 'Test that changing the iterationStart affects computed timing ' +
- 'when backwards-filling');
+}, 'Changing the value updates computed timing when backwards-filling');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ iterationStart: 0.2,
iterations: 1,
fill: 'both',
duration: 100,
delay: 0 });
anim.effect.timing.iterationStart = 2.5;
assert_equals(anim.effect.getComputedTiming().progress, 0.5);
assert_equals(anim.effect.getComputedTiming().currentIteration, 2);
-}, 'Test that changing the iterationStart affects computed timing ' +
- 'during the active phase');
+}, 'Changing the value updates computed timing during the active phase');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] },
{ iterationStart: 0.2,
iterations: 1,
fill: 'both',
duration: 100,
delay: 0 });
anim.finish();
anim.effect.timing.iterationStart = 2.5;
assert_equals(anim.effect.getComputedTiming().progress, 0.5);
assert_equals(anim.effect.getComputedTiming().currentIteration, 3);
-}, 'Test that changing the iterationStart affects computed timing ' +
- 'when forwards-filling');
+}, 'Changing the value updates computed timing when forwards-filling');
test(function(t) {
var div = createDiv(t);
var anim = div.animate(null);
for (let invalid of [-1, NaN, Infinity]) {
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.iterationStart = invalid;
}, 'setting ' + invalid);
assert_throws({ name: 'TypeError' }, function() {
div.animate({}, { iterationStart: invalid });
}, 'animate() with ' + invalid);
}
-}, 'Using invalid values should throw TypeError');
+}, 'Throws when setting invalid values');
</script>
</body>
--- a/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/iterations.html
+++ b/testing/web-platform/tests/web-animations/interfaces/AnimationEffectTiming/iterations.html
@@ -8,54 +8,54 @@
<body>
<div id="log"></div>
<script>
'use strict';
test(function(t) {
var anim = createDiv(t).animate(null);
assert_equals(anim.effect.timing.iterations, 1);
-}, 'Test default value');
+}, 'Has the default value 1');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.iterations = 2;
assert_equals(anim.effect.timing.iterations, 2, 'set duration 2');
assert_equals(anim.effect.getComputedTiming().iterations, 2,
'getComputedTiming() after set iterations 2');
-}, 'set iterations 2');
+}, 'Can be set to a double value');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
anim.effect.timing.iterations = Infinity;
assert_equals(anim.effect.timing.iterations, Infinity, 'set duration Infinity');
assert_equals(anim.effect.getComputedTiming().iterations, Infinity,
'getComputedTiming() after set iterations Infinity');
-}, 'set iterations Infinity');
+}, 'Can be set to infinity');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.iterations = -1;
});
-}, 'set negative iterations');
+}, 'Throws when setting a negative number');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.iterations = -Infinity;
});
-}, 'set negative infinity iterations ');
+}, 'Throws when setting negative infinity');
test(function(t) {
var div = createDiv(t);
var anim = div.animate({ opacity: [ 0, 1 ] }, 2000);
assert_throws({ name: 'TypeError' }, function() {
anim.effect.timing.iterations = NaN;
});
-}, 'set NaN iterations');
+}, 'Throws when setting a NaN value');
</script>
</body>