| OLD | NEW |
| 1 function testComputedStyle(a_value, c_value) | 1 function testComputedStyle(a_value, c_value) |
| 2 { | 2 { |
| 3 shouldBe("window.getComputedStyle(ancestor).getPropertyCSSValue('-webkit-tex
t-align-last').cssText", "'" + a_value + "'"); | 3 shouldBe("window.getComputedStyle(ancestor).getPropertyCSSValue('text-align-
last').cssText", "'" + a_value + "'"); |
| 4 shouldBe("window.getComputedStyle(child).getPropertyCSSValue('-webkit-text-a
lign-last').cssText", "'" + c_value + "'"); | 4 shouldBe("window.getComputedStyle(child).getPropertyCSSValue('text-align-las
t').cssText", "'" + c_value + "'"); |
| 5 debug(''); | 5 debug(''); |
| 6 } | 6 } |
| 7 | 7 |
| 8 function ownValueTest(a_value, c_value) | 8 function ownValueTest(a_value, c_value) |
| 9 { | 9 { |
| 10 debug("Value of ancestor is '" + a_value + ", while child is '" + c_value +
"':"); | 10 debug("Value of ancestor is '" + a_value + ", while child is '" + c_value +
"':"); |
| 11 ancestor.style.webkitTextAlignLast = a_value; | 11 ancestor.style.textAlignLast = a_value; |
| 12 child.style.webkitTextAlignLast = c_value; | 12 child.style.textAlignLast = c_value; |
| 13 testComputedStyle(a_value, c_value); | 13 testComputedStyle(a_value, c_value); |
| 14 } | 14 } |
| 15 | 15 |
| 16 function inheritanceTest(a_value) | 16 function inheritanceTest(a_value) |
| 17 { | 17 { |
| 18 debug("Value of ancestor is '" + a_value + "':"); | 18 debug("Value of ancestor is '" + a_value + "':"); |
| 19 ancestor.style.webkitTextAlignLast = a_value; | 19 ancestor.style.textAlignLast = a_value; |
| 20 testComputedStyle(a_value, a_value); | 20 testComputedStyle(a_value, a_value); |
| 21 } | 21 } |
| 22 | 22 |
| 23 description("This test checks that the value of -webkit-text-align-last is prope
rly inherited to the child."); | 23 description("This test checks that the value of text-align-last is properly inhe
rited to the child."); |
| 24 | 24 |
| 25 ancestor = document.getElementById('ancestor'); | 25 ancestor = document.getElementById('ancestor'); |
| 26 child = document.getElementById('child'); | 26 child = document.getElementById('child'); |
| 27 | 27 |
| 28 inheritanceTest("start"); | 28 inheritanceTest("start"); |
| 29 inheritanceTest("end"); | 29 inheritanceTest("end"); |
| 30 inheritanceTest("left"); | 30 inheritanceTest("left"); |
| 31 inheritanceTest("right"); | 31 inheritanceTest("right"); |
| 32 inheritanceTest("center"); | 32 inheritanceTest("center"); |
| 33 inheritanceTest("justify"); | 33 inheritanceTest("justify"); |
| 34 inheritanceTest("auto"); | 34 inheritanceTest("auto"); |
| 35 | 35 |
| 36 ownValueTest("start", "end"); | 36 ownValueTest("start", "end"); |
| 37 ownValueTest("left", "right"); | 37 ownValueTest("left", "right"); |
| OLD | NEW |