| <!DOCTYPE html> |
| <html> |
| <body> |
| <template id="target-template"> |
| <svg width="90" height="90"> |
| <feDisplacementMap class="target" /> |
| </svg> |
| </template> |
| <script src="resources/interpolation-test.js"></script> |
| <script> |
| 'use strict'; |
| assertAttributeInterpolation({ |
| property: 'xChannelSelector', |
| from: 'R', |
| to: 'A' |
| }, [ |
| {at: -2.4, is: 'R'}, |
| {at: 0, is: 'R'}, |
| {at: 0.2, is: 'R'}, |
| {at: 0.6, is: 'A'}, |
| {at: 1, is: 'A'}, |
| {at: 3.4, is: 'A'} |
| ]); |
| assertAttributeInterpolation({ |
| property: 'yChannelSelector', |
| from: 'B', |
| to: 'G' |
| }, [ |
| {at: -2.4, is: 'B'}, |
| {at: 0, is: 'B'}, |
| {at: 0.2, is: 'B'}, |
| {at: 0.6, is: 'G'}, |
| {at: 1, is: 'G'}, |
| {at: 3.4, is: 'G'} |
| ]); |
| </script> |
| </body> |
| </html> |