Reviewed by Adam.
authoralice.liu@apple.com <alice.liu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 18 Dec 2007 02:10:56 +0000 (02:10 +0000)
committeralice.liu@apple.com <alice.liu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 18 Dec 2007 02:10:56 +0000 (02:10 +0000)
        Test for <rdar://problem/5566435> window with no scrollbars can still be scrolled with wheelevent

        * fast/events/attempt-scroll-with-no-scrollbars-expected.txt: Added.
        * fast/events/attempt-scroll-with-no-scrollbars.html: Added.
        * platform/mac/Skipped:
        Adding to mac Skipped list because of <rdar://problem/5643675> window.scrollTo scrolls a window with no scrollbars
        * platform/win/Skipped:
        Adding to win Skipped list because of <rdar://problem/5132009> Windows DRT does not support multiple windows

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@28823 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/fast/events/attempt-scroll-with-no-scrollbars-expected.txt [new file with mode: 0644]
LayoutTests/fast/events/attempt-scroll-with-no-scrollbars.html [new file with mode: 0644]
LayoutTests/platform/mac/Skipped
LayoutTests/platform/win/Skipped

index e3df92535f4838735e87f021031426a6c1b43c25..89e3a3638989f5d4e29fb93b2a97f291914db17b 100644 (file)
@@ -1,3 +1,16 @@
+2007-12-17  Alice Liu  <alice.liu@apple.com>
+
+        Reviewed by Adam.
+
+        Test for <rdar://problem/5566435> window with no scrollbars can still be scrolled with wheelevent 
+
+        * fast/events/attempt-scroll-with-no-scrollbars-expected.txt: Added.
+        * fast/events/attempt-scroll-with-no-scrollbars.html: Added.
+        * platform/mac/Skipped: 
+        Adding to mac Skipped list because of <rdar://problem/5643675> window.scrollTo scrolls a window with no scrollbars
+        * platform/win/Skipped:
+        Adding to win Skipped list because of <rdar://problem/5132009> Windows DRT does not support multiple windows
+
 2007-12-17  Darin Adler  <darin@apple.com>
 
         - disabling this test until we can find a way to make it pass on diverse machines
diff --git a/LayoutTests/fast/events/attempt-scroll-with-no-scrollbars-expected.txt b/LayoutTests/fast/events/attempt-scroll-with-no-scrollbars-expected.txt
new file mode 100644 (file)
index 0000000..53cdf1e
--- /dev/null
@@ -0,0 +1 @@
+PASSED
diff --git a/LayoutTests/fast/events/attempt-scroll-with-no-scrollbars.html b/LayoutTests/fast/events/attempt-scroll-with-no-scrollbars.html
new file mode 100644 (file)
index 0000000..21f9ecf
--- /dev/null
@@ -0,0 +1,53 @@
+<html><head>
+<script>
+var theWinref;
+
+function test()
+{
+    if (window.layoutTestController) {
+        layoutTestController.setCanOpenWindows();
+        layoutTestController.waitUntilDone();
+        layoutTestController.dumpAsText();
+    }
+    theWinref = window.open('','_blank','scrollbars=no');
+    setTimeout(doNewWindow, 250);
+    setTimeout(printResult, 750);
+}
+
+function doNewWindow()
+{
+    theWinref.document.open();
+    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>");
+    theWinref.resizeTo(200,100);
+    theWinref.document.close();
+    theWinref.scrollTo(200,100);
+}
+
+function printResult()
+{
+    if (theWinref.document.body.scrollTop == 0)
+        document.getElementById("console").innerHTML = "PASSED";
+    else
+        document.getElementById("console").innerHTML = "FAILED - window should not have been scrolled but was scrolled to " + theWinref.document.body.scrollTop;
+    theWinref.close();
+    endTest();
+}
+
+function endTest()
+{
+    if (window.layoutTestController) {
+        if (theWinref.closed)
+            layoutTestController.notifyDone();
+        else
+            setTimeout("endTest()", 10);
+    }
+}
+
+</script>
+</head>
+<body onload="test();">
+<div id="console">
+NOT DONE YET
+</div>
+</body>
+</html>
index 234f011a7edfce691056d9c42a33a4f66473581a..3f0d31a727d9adc4ef335ae12032509b5c88e3d9 100644 (file)
@@ -1,2 +1,5 @@
 # <rdar://problem/5647952> fast/events/mouseout-on-window.html needs mac DRT to issue mouse out events
 fast/events/mouseout-on-window.html
+
+# <rdar://problem/5643675> window.scrollTo scrolls a window with no scrollbars
+fast/events/attempt-scroll-with-no-scrollbars.html
index 39965f55bbf5cf1b647cabdd9da0be2699aa7ff5..7e5650a59a15f81ad18519be26997eb2a832c319 100644 (file)
@@ -241,6 +241,7 @@ fast/forms/textfield-drag-into-disabled.html
 # DumpRenderTree doesn't support multiple windows <rdar://problem/5132009>
 fast/dom/open-and-close-by-DOM.html
 fast/dom/Document/early-document-access.html
+fast/events/attempt-scroll-with-no-scrollbars.html
 fast/history/history_reload.html
 http/tests/navigation/new-window-redirect-history.html
 http/tests/navigation/target-frame-from-window.html