| OLD | NEW |
| 1 <!DOCTYPE> | 1 <!DOCTYPE> |
| 2 | 2 |
| 3 <html> | 3 <html> |
| 4 <head> | 4 <head> |
| 5 <style> | 5 <style> |
| 6 .box { | 6 .box { |
| 7 height: 100px; | 7 height: 100px; |
| 8 width: 100px; | 8 width: 100px; |
| 9 margin: 50px; | 9 margin: 50px; |
| 10 border: 1px solid black; | 10 border: 1px solid black; |
| 11 text-align: center; | 11 text-align: center; |
| 12 padding: 20px; | 12 padding: 20px; |
| 13 background-repeat: no-repeat; | 13 background-repeat: no-repeat; |
| 14 -webkit-transition-duration: 1s; | 14 -webkit-transition-duration: 1s; |
| 15 -webkit-transition-timing-function: linear; | 15 -webkit-transition-timing-function: linear; |
| 16 -webkit-transition-property: box-shadow; | 16 -webkit-transition-property: box-shadow; |
| 17 } | 17 } |
| 18 | 18 |
| 19 #box { | 19 #box { |
| 20 box-shadow: inset 10px 20px 4px gray; | 20 box-shadow: inset 10px 20px 4px gray; |
| 21 } | 21 } |
| 22 | 22 |
| 23 #box.final { | 23 #box.final { |
| 24 box-shadow: inset 20px 10px 4px gray, 10px 10px 6px black; | 24 box-shadow: inset 20px 10px 4px gray, 10px 10px 6px black; |
| 25 } | 25 } |
| 26 | 26 |
| 27 </style> | 27 </style> |
| 28 <script src="resources/transition-test-helpers.js"></script> | 28 <script src="../animations/resources/animation-test-helpers.js"></script> |
| 29 <script type="text/javascript"> | 29 <script type="text/javascript"> |
| 30 | 30 |
| 31 const expectedValues = [ | 31 const expectedValues = [ |
| 32 // [time, element-id, property, expected-value, tolerance] | 32 // [time, element-id, property, expected-value, tolerance] |
| 33 [0.5, 'box', 'box-shadow', [15, 15, 5, 5], 4], | 33 [0.5, 'box', 'box-shadow', [15, 15, 5, 5], 4], |
| 34 ]; | 34 ]; |
| 35 | 35 |
| 36 function setupTest() | 36 function setupTest() |
| 37 { | 37 { |
| 38 document.getElementById('box').className = 'box final'; | 38 document.getElementById('box').className = 'box final'; |
| 39 } | 39 } |
| 40 | 40 |
| 41 runTransitionTest(expectedValues, setupTest, usePauseAPI); | 41 runTransitionTest(expectedValues, setupTest, usePauseAPI); |
| 42 </script> | 42 </script> |
| 43 </head> | 43 </head> |
| 44 <body> | 44 <body> |
| 45 | 45 |
| 46 <div id="box" class="box">BOX</div> | 46 <div id="box" class="box">BOX</div> |
| 47 <div id="result"></div> | 47 <div id="result"></div> |
| 48 | 48 |
| 49 </body> | 49 </body> |
| 50 </html> | 50 </html> |
| OLD | NEW |