| <!DOCTYPE html> |
| |
| <html lang="en"> |
| <head> |
| <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> |
| <title>Transition/Animation Test #1</title> |
| <style type="text/css" media="screen"> |
| #box { |
| position: absolute; |
| left: 0; |
| top: 100px; |
| height: 100px; |
| width: 100px; |
| background-color: blue; |
| animation-duration: 0.5s; |
| animation-timing-function: linear; |
| animation-name: "anim"; |
| transition-property: transform; |
| transition-duration: 10s; |
| } |
| @-webkit-keyframes "anim" { |
| from { transform: translateX(200px); } |
| to { transform: translateX(300px); } |
| } |
| </style> |
| <script src="../resources/ui-helper.js"></script> |
| <script src="resources/animation-test-helpers.js"></script> |
| <script type="text/javascript"> |
| |
| if (window.testRunner) |
| testRunner.dumpAsText(); |
| |
| const expectedValues = [ |
| // [animation-name, time, element-id, property, expected-value, tolerance] |
| [null, 0.55, "box", "transform", "none", null], |
| ]; |
| |
| window.addEventListener("DOMContentLoaded", async event => { |
| await UIHelper.waitForEvent(document.getElementById("box"), "animationend"); |
| await UIHelper.animationFrame(); |
| checkExpectedValue(expectedValues, 0); |
| endTest(); |
| }); |
| |
| </script> |
| </head> |
| <body> |
| This test has a transition and animation on the same property (-webkit-transform). But the transition is never triggered, |
| so nothing should be moving when the animation finishes. |
| <div id="box"> |
| </div> |
| <div id="result"> |
| </div> |
| </body> |
| </html> |