OLD | NEW |
(Empty) | |
| 1 <script src="../../resources/js-test.js"></script> |
| 2 <style> |
| 3 .noposition |
| 4 { |
| 5 background: url("foo.png"); |
| 6 background-size: contain; |
| 7 } |
| 8 .position1 |
| 9 { |
| 10 background: url("foo.png"); |
| 11 background-position: 1px; |
| 12 background-size: contain; |
| 13 } |
| 14 .position2 |
| 15 { |
| 16 background: url("foo.png"); |
| 17 background-position: 1px 1px; |
| 18 background-size: contain; |
| 19 } |
| 20 </style> |
| 21 <script> |
| 22 var cssRules = document.styleSheets[1].cssRules; |
| 23 |
| 24 shouldBe('cssRules.length', '3'); |
| 25 shouldBeEqualToString('cssRules[0].cssText', '.noposition { background: url("foo
.png") 0% 0% / contain; }'); |
| 26 shouldBeEqualToString('cssRules[1].cssText', '.position1 { background: url("foo.
png") 1px 50% / contain; }'); |
| 27 shouldBeEqualToString('cssRules[2].cssText', '.position2 { background: url("foo.
png") 1px 1px / contain; }'); |
| 28 </script> |
OLD | NEW |