7 if (window.layoutTestController) {
8 layoutTestController.setCanOpenWindows();
9 layoutTestController.waitUntilDone();
10 layoutTestController.dumpAsText();
12 theWinref = window.open('','_blank','scrollbars=no');
13 setTimeout(doNewWindow, 250);
14 setTimeout(printResult, 750);
17 function doNewWindow()
19 theWinref.document.open();
20 theWinref.document.write("<html><body><iframe height='100%' width='100%' src=''></iframe><div>If you can see this, the test has failed.</div></body></html>");
21 theWinref.resizeTo(200,100);
22 theWinref.document.close();
23 theWinref.scrollTo(200,100);
26 function printResult()
28 if (theWinref.document.body.scrollTop == 0)
29 document.getElementById("console").innerHTML = "PASSED";
31 document.getElementById("console").innerHTML = "FAILED - window should not have been scrolled but was scrolled to " + theWinref.document.body.scrollTop;
38 if (window.layoutTestController) {
40 layoutTestController.notifyDone();
42 setTimeout("endTest()", 10);
48 <body onload="test();">