mirror of
https://github.com/servo/servo.git
synced 2025-08-26 15:48:22 +01:00
Update web-platform-tests to revision 53f3408ffe1fd0e56a37aff4aaf1fa8441c41d6d
This commit is contained in:
parent
9b01a4cc97
commit
0edf0ececb
59 changed files with 2247 additions and 1071 deletions
|
@ -12,17 +12,17 @@ Guidelines for writing tests
|
|||
For example, if you want to test setting the start time, you might be
|
||||
tempted to put all the tests in:
|
||||
|
||||
> `/web-animations/Animation/startTime.html`
|
||||
> `/web-animations/interfaces/Animation/startTime.html`
|
||||
|
||||
However, in the spec most of the logic is in the “Set the animation
|
||||
start time“ procedure in the “Timing model” section.
|
||||
|
||||
Instead, try something like:
|
||||
|
||||
> * `/web-animations/timing-model/animation/set-the-animation-start-time.html`<br>
|
||||
> * `/web-animations/timing-model/animations/set-the-animation-start-time.html`<br>
|
||||
> Tests all the branches and inputs to the procedure as defined in the
|
||||
> spec (using the `Animation.startTime` API).
|
||||
> * `/web-animations/Animation/startTime.html`<br>
|
||||
> * `/web-animations/interfaces/Animation/startTime.html`<br>
|
||||
> Tests API-layer specific issues like mapping unresolved values to
|
||||
> null, etc.
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
promise_test(function(t) {
|
||||
var div = createDiv(t);
|
||||
var animation = div.animate({transform: ['none', 'translate(100px)']},
|
||||
var animation = div.animate({transform: ['translate(100px)', 'translate(100px)']},
|
||||
100 * MS_PER_SEC);
|
||||
return animation.ready.then(function() {
|
||||
assert_not_equals(getComputedStyle(div).transform, 'none',
|
||||
|
@ -26,7 +26,7 @@ promise_test(function(t) {
|
|||
|
||||
test(function(t) {
|
||||
var div = createDiv(t);
|
||||
var animation = div.animate({marginLeft: ['0px', '100px']},
|
||||
var animation = div.animate({marginLeft: ['100px', '200px']},
|
||||
100 * MS_PER_SEC);
|
||||
animation.effect.timing.easing = 'linear';
|
||||
animation.cancel();
|
||||
|
@ -34,7 +34,7 @@ test(function(t) {
|
|||
'margin-left style is not animated after cancelling');
|
||||
|
||||
animation.currentTime = 50 * MS_PER_SEC;
|
||||
assert_equals(getComputedStyle(div).marginLeft, '50px',
|
||||
assert_equals(getComputedStyle(div).marginLeft, '150px',
|
||||
'margin-left style is updated when cancelled animation is'
|
||||
+ ' seeked');
|
||||
}, 'After cancelling an animation, it can still be seeked');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue