<!DOCTYPE html>

<html>
<head>
    <style>
        body {
            height: 2000px;
        }
    </style>
    <script>
        if (window.testRunner) {
            testRunner.waitUntilDone();
            testRunner.dumpAsText();
        }

        function doTest()
        {
            window.scrollTo(0, 500);
            
            window.setTimeout(function() {
                window.internals.startTrackingRepaints();

                window.resizeBy(0, 10);
                var repaintRects = window.internals.repaintRectsAsText();
                window.internals.stopTrackingRepaints();

                document.getElementById('repaints').textContent = repaintRects;

                if (window.testRunner)
                    testRunner.notifyDone();
            }, 0);
        }
        
        window.addEventListener('load', doTest, false);
    </script>
</head>
<body>
    <p>In WebKit1 there should be a repaint at 0,-500.</p>
    <div id="repaints"></div>
</body>
</html>
