1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
2 "http://www.w3.org/TR/html4/loose.dtd">
6 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
7 <title>Test animation with multiple keyframes</title>
8 <style type="text/css" media="screen">
15 background-color: blue;
16 -webkit-animation-duration: 2s;
17 -webkit-animation-timing-function: linear;
18 -webkit-animation-name: anim;
20 @-webkit-keyframes anim {
27 <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
28 <script type="text/javascript" charset="utf-8">
30 const expectedValues = [
31 // [animation-name, time, element-id, property, expected-value, tolerance]
32 ["anim", 0.4, "box", "left", 20, 2],
33 ["anim", 1.2, "box", "left", 10, 2],
34 ["anim", 1.6, "box", "left", 15, 2],
37 runAnimationTest(expectedValues);
42 This test performs a keyframed animation of the left property. It animates over 2 seconds.
43 It takes 3 snapshots and expects each result to be within a specified range.