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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/forms/associatedFormControls-leak-nodes.html

Issue 2569763006: Make an existing workaround a bit broader. (Closed)
Patch Set: Created 4 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <body> 3 <body>
4 <iframe id="frame"></iframe> 4 <iframe id="frame"></iframe>
5 5
6 <script src="../../resources/js-test.js"></script> 6 <script src="../../resources/js-test.js"></script>
7 <script> 7 <script>
8 if (!window.internals) { 8 if (!window.internals) {
9 debug("This test only runs on \"content_shell --run-layout-test\", as it req uires existence of window.internals."); 9 debug("This test only runs on \"content_shell --run-layout-test\", as it req uires existence of window.internals.");
10 } else { 10 } else {
11 testRunner.waitUntilDone(); 11 testRunner.waitUntilDone();
12 window.jsTestIsAsync = true; 12 window.jsTestIsAsync = true;
13 var documentsBefore; 13 var documentsBefore;
14 var documentsAfter; 14 var documentsAfter;
15 // FIXME(keishi): Calling asyncGC twice to fix flakiness. 15 // FIXME(keishi): Calling asyncGC twice to fix flakiness, crbug.com/674194
16 asyncGC(function() { 16 asyncGC(function() {
17 asyncGC(function() { 17 asyncGC(function() {
18 documentsBefore = window.internals.numberOfLiveDocuments(); 18 documentsBefore = window.internals.numberOfLiveDocuments();
19 19
20 var frame = document.getElementById('frame'); 20 var frame = document.getElementById('frame');
21 frame.contentDocument.body.innerHTML = '<form></form>'; 21 frame.contentDocument.body.innerHTML = '<form></form>';
22 document.body.removeChild(frame); 22 document.body.removeChild(frame);
23 frame = null; 23 frame = null;
24 24
25 // FIXME(keishi): crbug.com/674194
25 asyncGC(function() { 26 asyncGC(function() {
26 documentsAfter = window.internals.numberOfLiveDocuments(); 27 asyncGC(function() {
28 documentsAfter = window.internals.numberOfLiveDocuments();
27 29
28 // -1 is from removing frame itself. 30 // -1 is from removing frame itself.
29 shouldBe('documentsBefore - 1', 'documentsAfter'); 31 shouldBe('documentsBefore - 1', 'documentsAfter');
30 finishJSTest(); 32 finishJSTest();
33 });
31 }); 34 });
32 }); 35 });
33 }); 36 });
34 } 37 }
35 </script> 38 </script>
36 </body> 39 </body>
37 </html> 40 </html>
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698