OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <script src="testharness/testharness.js"></script> |
| 3 <script src="testharness/testharnessreport.js"></script> |
| 4 <script src="resources/keyframes-test.js"></script> |
| 5 <script> |
| 6 test(function() { |
| 7 assertAnimationStyles([ |
| 8 {opacity: '0.5', left: '50px'}, |
| 9 {opacity: '0', left: '0px', offset: null}, |
| 10 {opacity: '0.75', left: '75px', offset: null}, |
| 11 ], { |
| 12 0: {opacity: '0.5', left: '50px'}, |
| 13 0.25: {opacity: '0.25', left: '25px'}, |
| 14 0.5: {opacity: '0', left: '0px'}, |
| 15 0.75: {opacity: '0.375', left: '37.5px'}, |
| 16 1: {opacity: '0.75', left: '75px'}, |
| 17 }, 'case A'); |
| 18 |
| 19 assertAnimationStyles([ |
| 20 {opacity: '0.5', left: '50px', offset: null}, |
| 21 {opacity: '0', left: '0px', offset: 0.25}, |
| 22 {opacity: '0.75', left: '75px', offset: null}, |
| 23 ], { |
| 24 0: {opacity: '0.5', left: '50px'}, |
| 25 0.125: {opacity: '0.25', left: '25px'}, |
| 26 0.25: {opacity: '0', left: '0px'}, |
| 27 0.5: {opacity: '0.25', left: '25px'}, |
| 28 0.75: {opacity: '0.5', left: '50px'}, |
| 29 1: {opacity: '0.75', left: '75px'}, |
| 30 }, 'case B'); |
| 31 }, |
| 32 'element.animate() with null offsets specified', |
| 33 { |
| 34 help: 'http://dev.w3.org/fxtf/web-animations/#the-keyframe-dictionary', |
| 35 assert: [ |
| 36 'element.animate() should start an animation when keyframes are specified wi
th', |
| 37 'null offsets. The behaviour should be identical to not specifying the offse
ts.', |
| 38 ], |
| 39 author: 'Alan Cutter', |
| 40 }); |
| 41 </script> |
OLD | NEW |