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

Side by Side Diff: LayoutTests/fast/dom/Window/property-access-on-cached-properties-after-frame-removed-and-gced.html

Issue 517043003: Move Frame to the Oilpan heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Back out non-Oilpan experiment + tidy up by adding frame() ref accessors Created 6 years, 3 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 src="resources/window-property-collector.js"></script> 4 <script src="resources/window-property-collector.js"></script>
5 <script> 5 <script>
6 var jsTestIsAsync = true; 6 var jsTestIsAsync = true;
7 7
8 var childWindow; 8 var childWindow;
9 var propertiesToVerify = []; 9 var propertiesToVerify = [];
10 10
(...skipping 11 matching lines...) Expand all
22 } 22 }
23 23
24 function runTest() 24 function runTest()
25 { 25 {
26 description("Tests access of cached DOMWindow properties after the associate d frame is removed from a web page and garbage collected. Test should not crash and properties should be set to sane defaults."); 26 description("Tests access of cached DOMWindow properties after the associate d frame is removed from a web page and garbage collected. Test should not crash and properties should be set to sane defaults.");
27 var frame = document.getElementById("frame"); 27 var frame = document.getElementById("frame");
28 childWindow = frame.contentWindow; 28 childWindow = frame.contentWindow;
29 // Have expected results assume that the frame has been closed (=> window.cl osed = true.) 29 // Have expected results assume that the frame has been closed (=> window.cl osed = true.)
30 collectProperties(true); 30 collectProperties(true);
31 frame.parentNode.removeChild(frame); 31 frame.parentNode.removeChild(frame);
32 window.setTimeout(verifyResults, 0); 32 asyncGC(function () {
33 } 33 for (var i = 0; i < propertiesToVerify.length; ++i)
34 34 shouldBe(propertiesToVerify[i].property, propertiesToVerify[i].expec ted);
35 function verifyResults() 35 finishJSTest();
36 { 36 });
37 if (window.gc)
38 gc();
39 for (var i = 0; i < propertiesToVerify.length; ++i)
40 shouldBe(propertiesToVerify[i].property, propertiesToVerify[i].expected) ;
41 finishJSTest();
42 } 37 }
43 </script> 38 </script>
44 </head> 39 </head>
45 <body> 40 <body>
46 <iframe id="frame" src="about:blank" onload="runTest()"></iframe> 41 <iframe id="frame" src="about:blank" onload="runTest()"></iframe>
47 </body> 42 </body>
48 </html> 43 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698