| <script src="../../resources/js-test-pre.js"></script> |
| description("Test to make sure the box-decoration-break property is correctly parsed.") |
| var testContainer = document.createElement("div"); |
| document.body.appendChild(testContainer); |
| testContainer.innerHTML = '<p id="test">Hello world</p>'; |
| e = document.getElementById('test'); |
| computedStyle = window.getComputedStyle(e, null); |
| e.style.webkitBoxDecorationBreak = "slice"; |
| shouldBe("e.style.getPropertyValue('-webkit-box-decoration-break')", "'slice'"); |
| shouldBe("computedStyle.getPropertyValue('-webkit-box-decoration-break')", "'slice'"); |
| e.style.webkitBoxDecorationBreak = "clone"; |
| shouldBe("e.style.getPropertyValue('-webkit-box-decoration-break')", "'clone'"); |
| shouldBe("computedStyle.getPropertyValue('-webkit-box-decoration-break')", "'clone'"); |
| e.style.webkitBoxDecorationBreak = ""; |
| e.style.webkitBoxDecorationBreak = "invalid"; |
| shouldBe("e.style.getPropertyValue('-webkit-box-decoration-break')", "null"); |
| shouldBe("computedStyle.getPropertyValue('-webkit-box-decoration-break')", "'slice'"); |
| document.body.removeChild(testContainer); |
| <script src="../../resources/js-test-post.js"></script> |