blob: b6623db3737235b81995dc63b4e6930a37e72e70 [file] [log] [blame]
<style type="text/css">
#container {
width: 200px;
height: 100px;
overflow: auto;
#replacedElement {
width: 200%;
height: 100%;
<script src="../../resources/js-test.js"></script>
<div id="container">
<img id="replacedElement" style="background:green"/>
description('Testcase for bug <a href=""></a>. \
When a container having overflow:auto has a horizontal scrollbar, \
the scrollbar is to be placed between the inner border edge and the outer padding edge. \
Thus the content height of a replaced child inside the container must not include the height of the horizontal scollbars.');
debug('The height of the inner element box should be 100% of the containers height minus the height of horizontal scrollbar. \
There should be no vertical scrollable content in the container<br>');
shouldBeTrue('document.getElementById("container").scrollHeight == document.getElementById("container").clientHeight');
debug('Container height = Inner replaced element height + scrollbar height');
shouldBeTrue('document.getElementById("container").offsetHeight > document.getElementById("replacedElement").offsetHeight');
<div id="description"></div>
<div id="console"></div>