blob: d1c540853b8732435bf5cdc61f774ed5b382aa4b [file] [log] [blame]
document.dir should reflect the 'dir' content attribute of the <html> element and should be settable in <head>.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Read document.dir in head
PASS headReadDocumentDir is ""
Write document.dir in head
PASS headWriteDocumentDir is "rtl"
Read document.dir in body
PASS document.dir is "rtl"
Read document.documentElement.dir in body
PASS document.documentElement.dir is "rtl"
Read document.body.dir in body
PASS document.body.dir is ""
Write document.dir in body
PASS document.dir is "ltr"
Read document.documentElement.dir in body
PASS document.documentElement.dir is "ltr"
Read document.body.dir in body
PASS document.body.dir is ""
Write non-canonical case document.dir in body
PASS document.dir = 'RTL' did not throw exception.
PASS document.documentElement.getAttribute('dir') is "RTL"
PASS document.dir is "rtl"
Write invalid document.dir in body
PASS document.dir = 'WRONG' did not throw exception.
PASS document.documentElement.getAttribute('dir') is "WRONG"
PASS document.dir is ""
Write non-canonical case document.body.dir in body
PASS document.body.dir = 'RTL' did not throw exception.
PASS document.body.getAttribute('dir') is "RTL"
PASS document.body.dir is "rtl"
Write invalid document.body.dir in body
PASS document.body.dir = 'WRONG' did not throw exception.
PASS document.body.getAttribute('dir') is "WRONG"
PASS document.body.dir is ""
PASS successfullyParsed is true
TEST COMPLETE