Files
browser/src/browser/tests/animation/animation.html
2025-12-25 17:00:27 +08:00

16 lines
413 B
HTML

<!DOCTYPE html>
<script src="../testing.js"></script>
<script id=animation>
let a1 = document.createElement('div').animate(null, null);
testing.expectEqual('finished', a1.playState);
let cb = [];
a1.ready.then(() => { cb.push('ready') });
a1.finished.then((x) => {
cb.push('finished');
cb.push(x == a1);
});
testing.eventually(() => testing.expectEqual(['finished', true], cb));
</script>