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 concurrent animations
</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: anim1;
20 @-webkit-keyframes anim1 {
32 background-color: blue;
33 -webkit-animation-duration:
2s;
34 -webkit-animation-timing-function: linear;
35 -webkit-animation-name: anim2;
37 @-webkit-keyframes anim2 {
43 <script src=
"resources/animation-test-helpers.js" type=
"text/javascript" charset=
"utf-8"></script>
44 <script type=
"text/javascript" charset=
"utf-8">
46 const expectedValues = [
47 // [time, element-id, property, expected-value, tolerance]
48 [
0.4,
"box1",
"left",
20,
2],
49 [
0.5,
"box2",
"left",
20,
2],
50 [
1.0,
"box2",
"left",
30,
2],
51 [
1.2,
"box1",
"left",
10,
2],
52 [
1.5,
"box2",
"left",
25,
2],
53 [
1.6,
"box1",
"left",
15,
2],
56 runAnimationTest(expectedValues);
61 This test performs animations of the left property on two boxes over
2 seconds.
62 It takes
3 snapshots each and expects each result to be within a specified range.