<html> <!-- webkit-test-runner [ MockScrollbarsControllerEnabled=true ] -->
<style>
    #scrollme {
        width: 100px;
        height: 100px;
        overflow: auto;
    }
    #scrollme p {
        height: 1000px;
    }
</style>
<script src="../../resources/js-test-pre.js"></script>
<script>
    jsTestIsAsync = true;

    window.onload = function() {
        if (window.internals)
            internals.updateLayoutAndStyleForAllFrames();
        var div = document.querySelector('#scrollme');
        if (window.eventSender) {
            eventSender.mouseMoveTo(0, 0);
            eventSender.mouseMoveTo(div.offsetLeft + 1, div.offsetTop + 1);
            eventSender.mouseMoveTo(div.offsetLeft + div.offsetWidth - 4, div.offsetTop + 1);
            eventSender.mouseDown();
            eventSender.mouseUp();
            eventSender.mouseMoveTo(0, 0);
        }
        finishJSTest();
    };
</script>
<script src="../../resources/js-test-post.js"></script>
<body>
  <div id="scrollme"><p>This is a scrollable div.</p></div>
  <pre id="console"></pre>
</body>
</html>
