<!doctype html> | |
<html> | |
<script src="../../resources/js-test.js"></script> | |
<script> | |
if (window.testRunner) | |
testRunner.waitUntilDone(); | |
description('This tests that setting the dir attribute to rtl and clearing it defaults to ltr.'); | |
onload = function() { | |
document.body.dir = 'rtl'; | |
document.body.offsetTop; | |
document.body.dir = ''; | |
shouldBeEqualToString('window.getComputedStyle(document.body).direction', 'ltr'); | |
if (window.testRunner) | |
testRunner.notifyDone(); | |
} | |
</script> | |
<body> |