blob: b6a239cc4897119e6cad4438b131478eb3a639af [file] [log] [blame]
<!DOCTYPE HTML>
<html>
<head>
<title>This tests that autosize works fine with precent heights</title>
<style>
html {
height: 100%;
}
</style>
<script>
if (window.internals)
internals.enableSizeToContentAutoSizeMode(true, 200, 600);
if (window.testRunner)
testRunner.dumpAsText();
</script>
</head>
<body style="height: 100%;">
<div style="height: 100%; display: flex; flex-direction: column;">
<div>
<div style="width: 10px; height: 100px; background-color: green;"></div>
</div>
<div style="overflow: hidden;">
<div style="width: 10px; height: 100px; background-color: blue;"></div>
</div>
</div>
</body>
<script>
document.body.innerText = "PASS if body is 200px: " + document.body.offsetHeight;
if (window.internals)
internals.enableSizeToContentAutoSizeMode(false, 0, 0, 0, 0);
</script>
</html>