mirror of
https://github.com/servo/servo.git
synced 2025-09-09 22:48:21 +01:00
Update web-platform-tests to revision be5419e845d39089ba6dc338c1bd0fa279108317
This commit is contained in:
parent
aa199307c8
commit
2b6f573eb5
3440 changed files with 109438 additions and 41750 deletions
|
@ -1,7 +1,7 @@
|
|||
Web Animations Test Suite
|
||||
=========================
|
||||
|
||||
Specification: https://w3c.github.io/web-animations/
|
||||
Specification: https://drafts.csswg.org/web-animations/
|
||||
|
||||
|
||||
Guidelines for writing tests
|
||||
|
@ -51,24 +51,24 @@ Guidelines for writing tests
|
|||
e.g.
|
||||
|
||||
```javascript
|
||||
test(function(t) {
|
||||
test(t => {
|
||||
const animation = createDiv(t).animate(null);
|
||||
assert_class_string(animation, 'Animation', 'Returned object is an Animation');
|
||||
}, 'Element.animate() creates an Animation object');
|
||||
```
|
||||
|
||||
```javascript
|
||||
test(function(t) {
|
||||
assert_throws({ name: 'TypeError' }, function() {
|
||||
test(t => {
|
||||
assert_throws({ name: 'TypeError' }, () => {
|
||||
createDiv(t).animate(null, -1);
|
||||
});
|
||||
}, 'Setting a negative duration throws a TypeError');
|
||||
```
|
||||
|
||||
```javascript
|
||||
promise_test(function(t) {
|
||||
promise_test(t => {
|
||||
const animation = createDiv(t).animate(null, 100 * MS_PER_SEC);
|
||||
return animation.ready.then(function() {
|
||||
return animation.ready.then(() => {
|
||||
assert_greater_than(animation.startTime, 0, 'startTime when running');
|
||||
});
|
||||
}, 'startTime is resolved when running');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue