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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/dom/Window/name-and-opener-on-detached-window.html

Issue 1475863005: [Async][WIP] Call FrameLoader::checkCompleted() asynchronously to avoid sync body.onload() Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 10 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
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 <script> 4 <script>
5 var jsTestIsAsync = true;
6
5 var childWindow; 7 var childWindow;
6 var propertiesToVerify = []; 8 var propertiesToVerify = [];
7 9
8 function runTest() 10 function runTest()
9 { 11 {
10 description("Tests that getting and setting name and opener on a cached DOMW indow after the associated frame is removed from a web page does not crash."); 12 description("Tests that getting and setting name and opener on a cached DOMW indow after the associated frame is removed from a web page does not crash.");
11 var frame = document.getElementById("frame"); 13 var frame = document.getElementById("frame");
12 childWindow = frame.contentWindow; 14 childWindow = frame.contentWindow;
13 childWindow.name = "oldname"; 15 childWindow.name = "oldname";
14 shouldBe("childWindow.name", "'oldname'"); 16 shouldBe("childWindow.name", "'oldname'");
15 frame.parentNode.removeChild(frame); 17 frame.parentNode.removeChild(frame);
16 childWindow.opener = null; 18 childWindow.opener = null;
17 shouldBeNull("childWindow.opener"); 19 shouldBeNull("childWindow.opener");
18 childWindow.name = "newname"; 20 childWindow.name = "newname";
19 shouldBe("childWindow.name", "''"); 21 shouldBe("childWindow.name", "''");
22 finishJSTest();
20 } 23 }
21 </script> 24 </script>
22 </head> 25 </head>
23 <body> 26 <body>
24 <iframe id="frame" src="about:blank" onload="runTest()"></iframe> 27 <iframe id="frame" src="about:blank" onload="runTest()"></iframe>
25 </body> 28 </body>
26 </html> 29 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698