blob: 82bbf214d5a233092fa75e07a5028e8fa09d1c60 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<title>Viewport 'min-width' descriptor has 'extend-to-zoom' value</title>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<style>
html, body { width: 100%; height: 100%; margin: 0 }
@viewport { min-width: -internal-extend-to-zoom 200px; zoom: 1.0; }
</style>
</head>
<body>
<div id="log"></div>
<script>
test(function(){
assert_true(window.internals instanceof Object);
}, "Check that window.internals is present. Required to call viewportAsText.");
var actualWidth;
var actualHeight;
var vpString = internals.viewportAsText(document, 1, 320, 352);
var match = /viewport size (.+)x(.+) scale (.+ )/.exec(vpString);
if (match) {
actualWidth = parseFloat(match[1]);
}
test(function(){
assert_equals(actualWidth, 320);
}, "Check viewport width.");
</script>
</body>
</html>