blob: 0ac79a9fb6300d741e5fc767429c33a69462b1a0 [file] [log] [blame]
simon.fraser@apple.comc2588ab2015-10-25 01:33:02 +00001<!DOCTYPE html>
2<html>
3<head>
4 <style>
5 #box1 {
6 position: relative;
7 left: 10px;
8 top: 10px;
9 height: 100px;
10 width: 100px;
11 background-color: blue;
dino@apple.com9c263802016-08-02 23:43:30 +000012 animation: anim1 0 2s linear forwards;
simon.fraser@apple.comc2588ab2015-10-25 01:33:02 +000013 }
14 @keyframes anim1 {
15 from { left: 400px; }
16 25% { left: 0px; }
17 51% { left: 250px; }
18 to { left: 100px; }
19 }
20 </style>
21 <script src="resources/animation-test-helpers.js"></script>
22 <script>
23
24 const expectedValues = [
25 // [animation-name, time, element-id, property, expected-value, tolerance]
jbedard@apple.comba9b1ed2018-04-17 23:08:31 +000026 ["anim1", 1, "box1", "left", 100, 2],
simon.fraser@apple.comc2588ab2015-10-25 01:33:02 +000027 ];
28
29 runAnimationTest(expectedValues);
30 </script>
31</head>
32<body>
33<p>Fill-forwards state should be the last keyframe state, even with a zero-duration animation.</p>
34<div id="box1"></div>
35<div id="result"></div>
36</body>
37</html>