dino@apple.com | 5863503 | 2018-09-12 20:59:33 +0000 | [diff] [blame] | 1 | <!DOCTYPE html><!-- webkit-test-runner [ experimental:WebAnimationsCSSIntegrationEnabled=true ] --> |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 2 | |
simon.fraser@apple.com | 4803cdd | 2011-04-26 03:25:14 +0000 | [diff] [blame] | 3 | <html> |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 4 | <head> |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 5 | <style> |
simon.fraser@apple.com | 3d92c2b | 2011-04-26 21:49:10 +0000 | [diff] [blame] | 6 | #target { |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 7 | position: relative; |
| 8 | left: 100px; |
dino@apple.com | 60c426a | 2008-12-03 20:00:58 +0000 | [diff] [blame] | 9 | height: 50px; |
| 10 | width: 50px; |
| 11 | background-color: green; |
simon.fraser@apple.com | 3d92c2b | 2011-04-26 21:49:10 +0000 | [diff] [blame] | 12 | -webkit-transition: left 1s linear 250ms; |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 13 | } |
| 14 | |
simon.fraser@apple.com | 3d92c2b | 2011-04-26 21:49:10 +0000 | [diff] [blame] | 15 | #target.moved { |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 16 | left: 200px; |
| 17 | } |
simon.fraser@apple.com | 6510a13 | 2009-08-03 19:40:12 +0000 | [diff] [blame] | 18 | </style> |
simon.fraser@apple.com | 4803cdd | 2011-04-26 03:25:14 +0000 | [diff] [blame] | 19 | <script src="resources/transition-test-helpers.js"></script> |
simon.fraser@apple.com | 3d92c2b | 2011-04-26 21:49:10 +0000 | [diff] [blame] | 20 | <script> |
| 21 | const expectedValues = [ |
| 22 | // [time, element-id, property, expected-value, tolerance] |
| 23 | [0.5, "target", "left", 125, 4], |
| 24 | ]; |
| 25 | |
| 26 | function setupTest() |
| 27 | { |
| 28 | document.getElementById("target").className = "moved"; |
| 29 | } |
| 30 | |
commit-queue@webkit.org | 70ac10b | 2012-11-27 19:16:27 +0000 | [diff] [blame] | 31 | runTransitionTest(expectedValues, setupTest, usePauseAPI); |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 32 | </script> |
| 33 | </head> |
simon.fraser@apple.com | 3d92c2b | 2011-04-26 21:49:10 +0000 | [diff] [blame] | 34 | <body> |
| 35 | <div id="target"></div> |
| 36 | <div id="result"></div> |
simon.fraser@apple.com | e5d2c89 | 2008-11-21 00:48:46 +0000 | [diff] [blame] | 37 | |
| 38 | </body> |
| 39 | </html> |