301361d8135e7bbd14f11e82c3a6709d92aa9033
[WebKit-https.git] / LayoutTests / animations / fill-forwards-end-state.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4   <title>Test animation with multiple concurrent animations</title>
5   <style type="text/css" media="screen">
6     #box1 {
7       position: relative;
8       left: 10px;
9       top: 10px;
10       height: 100px;
11       width: 100px;
12       background-color: blue;
13       animation-fill-mode: forwards;
14       animation: anim1 2s 0.2s linear;
15     }
16     @keyframes anim1 {
17         from { left: 100px; }
18         40%  { left: 0px; }
19         60%  { left: 250px; }
20         to   { left: 100px; }
21     }
22   </style>
23   <script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
24   <script type="text/javascript" charset="utf-8">
25
26     const expectedValues = [
27       // [animation-name, time, element-id, property, expected-value, tolerance]
28       ["anim1", 2.5, "box1", "left", 100, 2],
29     ];
30
31     var disablePauseAnimationAPI = false;
32     runAnimationTest(expectedValues, null, null, disablePauseAnimationAPI);
33   </script>
34 </head>
35 <body>
36 <p>Fill-forwards state should be the last keyframe state.</p>
37 <div id="box1"></div>
38 <div id="result"></div>
39 </body>
40 </html>