| var headReadDocumentDir = document.dir; |
| var headWriteDocumentDir = document.dir; |
| <div id="description"></div> |
| <script src="../../resources/js-test-pre.js"></script> |
| description("This tests:<br>" |
| + "Bug 9954 REGRESSION: document.dir should return empty string in <head><br>" |
| + "<a href=\"https://bugs.webkit.org/show_bug.cgi?id=9954\">https://bugs.webkit.org/show_bug.cgi?id=9954</a><br>"); |
| debug("Read document.dir in head"); |
| shouldBe("headReadDocumentDir", "''"); |
| debug("Write document.dir in head"); |
| shouldBe("headWriteDocumentDir", "''"); |
| debug("Read document.dir in body"); |
| shouldBe("document.dir", "''"); |
| debug("Read document.body.dir in body"); |
| shouldBe("document.body.dir", "''"); |
| debug("Write document.dir in body"); |
| shouldBe("document.dir", "'ltr'"); |
| debug("Read document.body.dir in body"); |
| shouldBe("document.body.dir", "'ltr'"); |
| <script src="../../resources/js-test-post.js"></script> |