| OLD | NEW |
| (Empty) |
| 1 <pre id="console"></pre> | |
| 2 <script> | |
| 3 if (window.testRunner) | |
| 4 testRunner.dumpAsText(); | |
| 5 | |
| 6 function log(message) | |
| 7 { | |
| 8 document.getElementById("console").appendChild(document.createTextNode(m
essage + "\n")); | |
| 9 } | |
| 10 | |
| 11 function test(declaration, expectedHyphenateLimit) | |
| 12 { | |
| 13 var element = document.createElement("div"); | |
| 14 element.style.cssText = declaration; | |
| 15 var hyphenateLimit = element.style.webkitHyphenateLimitLines; | |
| 16 if (hyphenateLimit === expectedHyphenateLimit) | |
| 17 log("PASS: '" + declaration + "' parsed as '" + hyphenateLimit + "'"
); | |
| 18 else | |
| 19 log("FAIL: '" + declaration + "' parsed as '" + hyphenateLimit + "'"
); | |
| 20 } | |
| 21 | |
| 22 test('-webkit-hyphenate-limit-lines: initial;', 'initial'); | |
| 23 test('-webkit-hyphenate-limit-lines: inherit;', 'inherit'); | |
| 24 test('-webkit-hyphenate-limit-lines: no-limit;', 'no-limit'); | |
| 25 test('-webkit-hyphenate-limit-lines: 0;', '0'); | |
| 26 test('-webkit-hyphenate-limit-lines: 4;', '4'); | |
| 27 test('-webkit-hyphenate-limit-lines: 2 2;', ''); | |
| 28 test('-webkit-hyphenate-limit-lines: 2px;', ''); | |
| 29 test('-webkit-hyphenate-limit-lines: -1;', ''); | |
| 30 test('-webkit-hyphenate-limit-lines: "1";', ''); | |
| 31 </script> | |
| OLD | NEW |