blob: 04b4bfcb1bf08c992d4e82549cf0b5bee51b8c48 [file] [log] [blame]
<!DOCTYPE html>
<script src="../../resources/js-test.js"></script>
<style>
#block {
width: 200.5px;
height: 200.5px;
}
#inlineContainer {
display: inline-block;
width: 200px;
}
#inlineContainer > span {
height: 30px;
display: inline-block;
width: calc(100% / 3);
}
</style>
<body>
<div id="block"></div>
<div id="inlineContainer">
<span></span><span id="inline"></span>
</div>
<script>
var test;
function checkSizesAreEqual(id) {
test = document.getElementById(id);
shouldBeTrue("test.scrollWidth == test.offsetWidth");
shouldBeTrue("test.scrollHeight == test.offsetHeight");
}
checkSizesAreEqual("block");
checkSizesAreEqual("inline");
</script>