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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/html/pending-stylesheet-crash.html

Issue 2847943002: Cleanup LayoutTests that define a function gc(). (Closed)
Patch Set: Fixing Layout Tests Failures Created 3 years, 7 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 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html> 2 <html>
3 <head id="h"> 3 <head id="h">
4 </head> 4 </head>
5 <body> 5 <body>
6 <script src="../../resources/gc.js"></script>
6 <script> 7 <script>
7 if (window.testRunner) 8 if (window.testRunner)
8 window.testRunner.dumpAsText(); 9 window.testRunner.dumpAsText();
9 10
10 var link = document.createElement('link'); 11 var link = document.createElement('link');
11 link.setAttribute('type', 'text/css'); 12 link.setAttribute('type', 'text/css');
12 link.setAttribute('rel', 'stylesheet'); 13 link.setAttribute('rel', 'stylesheet');
13 link.setAttribute('href', 'really-does-not-exist.css'); 14 link.setAttribute('href', 'really-does-not-exist.css');
14 document.getElementById('h').appendChild(link); 15 document.getElementById('h').appendChild(link);
15 link.parentNode.removeChild(link); 16 link.parentNode.removeChild(link);
16 link = null; 17 link = null;
17 </script> 18 </script>
18 <script> 19 <script>
19 function gc() {
20 if (window.GCController)
21 GCController.collect();
22 else {
23 // Allocate a sufficient number of objects to force a GC.
24 for (var i = 0; i < 10000; i++)
25 new Object;
26 }
27 }
28
29 gc(); 20 gc();
30 </script> 21 </script>
31 <p>This test passes if it doesn't crash</p> 22 <p>This test passes if it doesn't crash</p>
32 </body> 23 </body>
33 </html> 24 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698