| OLD | NEW |
| (Empty) |
| 1 <script src="../resources/testharness.js"></script> | |
| 2 <script src="../resources/testharnessreport.js"></script> | |
| 3 <svg> | |
| 4 <stop id="target" offset="1"/> | |
| 5 </svg> | |
| 6 <script> | |
| 7 var asyncHandle = async_test('SVG Attributes should return to their base values
after animations have stopped applying.'); | |
| 8 | |
| 9 var animation = target.animate([ | |
| 10 {'svg-offset': '0'}, | |
| 11 {'svg-offset': '0.5'}, | |
| 12 ], 1000); | |
| 13 animation.pause(); | |
| 14 animation.currentTime = 500; | |
| 15 | |
| 16 requestAnimationFrame(() => { | |
| 17 asyncHandle.step(() => { | |
| 18 assert_equals(target.offset.animVal, 0.25, 'Animation is in effect.'); | |
| 19 }); | |
| 20 animation.cancel(); | |
| 21 requestAnimationFrame(() => { | |
| 22 asyncHandle.step(() => { | |
| 23 assert_equals(target.offset.animVal, 1, 'Animation is no longer in effect.
'); | |
| 24 }); | |
| 25 asyncHandle.done(); | |
| 26 }); | |
| 27 }); | |
| 28 </script> | |
| OLD | NEW |