Adding layout test for contentWindow for frames
authoradele <adele@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Sep 2004 00:58:02 +0000 (00:58 +0000)
committeradele <adele@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Sep 2004 00:58:02 +0000 (00:58 +0000)
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@7432 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/fast/frames/contentWindow_Frame-expected.txt [new file with mode: 0644]
LayoutTests/fast/frames/contentWindow_Frame.html [new file with mode: 0644]
LayoutTests/fast/frames/resources/frame_top.html [new file with mode: 0644]

diff --git a/LayoutTests/fast/frames/contentWindow_Frame-expected.txt b/LayoutTests/fast/frames/contentWindow_Frame-expected.txt
new file mode 100644 (file)
index 0000000..62ddc01
--- /dev/null
@@ -0,0 +1,17 @@
+layer at (0,0) size 800x600
+  RenderCanvas at (0,0) size 800x600
+layer at (0,0) size 800x600
+  RenderBlock {HTML} at (0,0) size 800x600
+    RenderFrameSet {FRAMESET} at (0,0) size 800x600
+      RenderFrame {FRAME} at (0,0) size 800x178
+        layer at (0,0) size 783x174
+          RenderCanvas at (0,0) size 783x174
+        layer at (0,0) size 783x174
+          RenderBlock {HTML} at (0,0) size 783x174
+            RenderBody {BODY} at (8,8) size 767x158
+              RenderBlock {DIV} at (0,0) size 767x18
+                RenderText {TEXT} at (0,0) size 74x18
+                  text run at (0,0) width 74: "about:blank"
+      RenderFrame {FRAME} at (0,182) size 800x417
+        layer at (0,0) size 783x413
+          RenderCanvas at (0,0) size 783x413
diff --git a/LayoutTests/fast/frames/contentWindow_Frame.html b/LayoutTests/fast/frames/contentWindow_Frame.html
new file mode 100644 (file)
index 0000000..67bd65a
--- /dev/null
@@ -0,0 +1,31 @@
+<html>
+
+<head>
+
+       <title>Testing contentWindow on Frames</title>
+
+       <script>
+               function putText()
+               {
+                       var t = document.getElementById("t_frame");
+                       var b = document.getElementById("b_frame");
+       
+                       var dv = t.contentDocument.getElementById("my_div");
+                       
+                       dv.innerText = b.contentWindow.location;
+
+               }
+       </script>
+
+</head>
+
+<body onload="putText()">
+
+  <FRAMESET rows="30%, 70%">
+      <FRAME id="t_frame" name="top" src="resources/frame_top.html">
+      <FRAME id="b_frame" name="bottom" src="about:blank">
+ </FRAMESET>
+
+</body>
+
+</html>
diff --git a/LayoutTests/fast/frames/resources/frame_top.html b/LayoutTests/fast/frames/resources/frame_top.html
new file mode 100644 (file)
index 0000000..a4e75da
--- /dev/null
@@ -0,0 +1,11 @@
+<html>
+
+<body>
+
+       <div id="my_div">
+       div text will be replaced
+       </div>
+
+</body>
+
+</html>