| <!DOCTYPE html> |
| <style> |
| .target { |
| font-size: 4px; |
| } |
| </style> |
| <script src="resources/responsive-test.js"></script> |
| <script> |
| assertCSSResponsive({ |
| property: 'line-height', |
| from: 'inherit', |
| to: '200px', |
| configurations: [{ |
| state: {inherited: '100px'}, |
| expect: [ |
| {at: 0.25, is: '125px'}, |
| {at: 0.75, is: '175px'}, |
| ], |
| }, { |
| state: {inherited: '10'}, |
| expect: [ |
| {at: 0.25, is: '40px'}, |
| {at: 0.75, is: '200px'}, |
| ], |
| }], |
| }); |
| |
| assertCSSResponsive({ |
| property: 'line-height', |
| from: neutralKeyframe, |
| to: '200px', |
| configurations: [{ |
| state: {underlying: '10'}, |
| expect: [ |
| {at: 0.25, is: '40px'}, |
| {at: 0.75, is: '200px'}, |
| ], |
| }, { |
| state: {underlying: '100px'}, |
| expect: [ |
| {at: 0.25, is: '125px'}, |
| {at: 0.75, is: '175px'}, |
| ], |
| }, { |
| state: {underlying: 'normal'}, |
| expect: [ |
| {at: 0.25, is: 'normal'}, |
| {at: 0.75, is: '200px'}, |
| ], |
| }, { |
| state: {underlying: 'inherit', inherited: '10'}, |
| expect: [ |
| {at: 0.25, is: '40px'}, |
| {at: 0.75, is: '200px'}, |
| ], |
| }, { |
| state: {underlying: 'inherit', inherited: '100px'}, |
| expect: [ |
| {at: 0.25, is: '125px'}, |
| {at: 0.75, is: '175px'}, |
| ], |
| }, { |
| state: {underlying: 'inherit', inherited: 'normal'}, |
| expect: [ |
| {at: 0.25, is: 'normal'}, |
| {at: 0.75, is: '200px'}, |
| ], |
| }], |
| }); |
| |
| assertCSSResponsive({ |
| property: 'line-height', |
| from: neutralKeyframe, |
| to: '20', |
| configurations: [{ |
| state: {underlying: '10'}, |
| expect: [ |
| {at: 0.25, is: '50px'}, |
| {at: 0.75, is: '70px'}, |
| ], |
| }, { |
| state: {underlying: '100px'}, |
| expect: [ |
| {at: 0.25, is: '100px'}, |
| {at: 0.75, is: '80px'}, |
| ], |
| }, { |
| state: {underlying: 'normal'}, |
| expect: [ |
| {at: 0.25, is: 'normal'}, |
| {at: 0.75, is: '80px'}, |
| ], |
| }, { |
| state: {underlying: 'inherit', inherited: '10'}, |
| expect: [ |
| {at: 0.25, is: '50px'}, |
| {at: 0.75, is: '70px'}, |
| ], |
| }, { |
| state: {underlying: 'inherit', inherited: '100px'}, |
| expect: [ |
| {at: 0.25, is: '100px'}, |
| {at: 0.75, is: '80px'}, |
| ], |
| }, { |
| state: {underlying: 'inherit', inherited: 'normal'}, |
| expect: [ |
| {at: 0.25, is: 'normal'}, |
| {at: 0.75, is: '80px'}, |
| ], |
| }], |
| }); |
| </script> |