chromium/third_party/blink/web_tests/fast/dom/Element/scale-page-bounding-client-rect-in-frame.html

<!DOCTYPE html>
<html>
<head>
<script>
function testRects()
{
    if (!window.testRunner || !window.eventSender || !window.internals)
        return;
    testRunner.dumpAsText();

    var div = document.getElementById("frame").contentDocument.getElementById("div");
    var rect = div.getBoundingClientRect();
    internals.setPageScaleFactor(2);
    var scaledRect = div.getBoundingClientRect();

    var result = document.getElementById("result");
    if (rect.left == scaledRect.left &&
        rect.top == scaledRect.top &&
        rect.right == scaledRect.right &&
        rect.bottom == scaledRect.bottom)
        result.innerHTML = "Pass";
    else
        result.innerHTML = "Fail";
}
</script>
</head>

<body onload="testRects();">
    <iframe id="frame" src="resources/client-rect-frame.html" width="300" height="200"></iframe>
    <p id="result">This test must be run via DumpRenderTree.</p>
</body>
</html>