Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(459)

Side by Side Diff: LayoutTests/fast/frames/out-of-document-iframe-has-child-frame.html

Issue 221673003: Defer iframe JavaScript URL evaluation (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../../resources/js-test.js"></script> 3 <script src="../../resources/js-test.js"></script>
4 </head> 4 </head>
5 <body> 5 <body>
6 <div id="main"/> 6 <div id="main"/>
7 <script> 7 <script>
8 description("This tests that several ways of making an iframe that isn't inserte d into a document tree" 8 description("This tests that several ways of making an iframe that isn't inserte d into a document tree"
9 + " but has a child frame will fail."); 9 + " but has a child frame will fail.");
10 10
11 main = document.getElementById("main"); 11 main = document.getElementById("main");
12 window.jsTestIsAsync = true;
12 13
13 try { 14 try {
14 container = main.appendChild(document.createElement("div")); 15 container = main.appendChild(document.createElement("div"));
15 helperFrame = container.appendChild(document.createElement("iframe")); 16 helperFrame = container.appendChild(document.createElement("iframe"));
16 targetFrame1 = document.createElement("iframe"); 17 targetFrame1 = document.createElement("iframe");
17 18
18 helperFrame.contentWindow.onunload = function() { 19 helperFrame.contentWindow.onunload = function() {
19 container.insertBefore(targetFrame1, helperFrame); 20 container.insertBefore(targetFrame1, helperFrame);
20 } 21 }
21 22
(...skipping 15 matching lines...) Expand all
37 } catch (e) { } 38 } catch (e) { }
38 shouldBeTrue("targetFrame2.contentWindow == undefined"); 39 shouldBeTrue("targetFrame2.contentWindow == undefined");
39 40
40 try { 41 try {
41 container = document.createElement("div"); 42 container = document.createElement("div");
42 targetFrame3 = container.appendChild(document.createElement("iframe")); 43 targetFrame3 = container.appendChild(document.createElement("iframe"));
43 helperFrame = targetFrame3.appendChild(document.createElement("iframe")); 44 helperFrame = targetFrame3.appendChild(document.createElement("iframe"));
44 helperFrame.src = "javascript:top.container.removeChild(top.targetFrame3)"; 45 helperFrame.src = "javascript:top.container.removeChild(top.targetFrame3)";
45 document.body.appendChild(container); 46 document.body.appendChild(container);
46 } catch (e) { } 47 } catch (e) { }
47 shouldBeTrue("targetFrame3.contentWindow == undefined");
48 48
49 isSuccessfullyParsed(); 49 setTimeout(function() {
50 shouldBeTrue("targetFrame3.contentWindow == undefined");
51 finishJSTest();
52 }, 0);
53
54
50 </script> 55 </script>
51 </body> 56 </body>
52 </html> 57 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698