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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/dom/HTMLElement/class-list-gc.html

Issue 2667393002: Stop using script-tests in fast/dom/. (Closed)
Patch Set: . Created 3 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 <!DOCTYPE html> 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="../../../resources/js-test.js"></script> 4 <script src="../../../resources/js-test.js"></script>
5 </head> 5 </head>
6 <body> 6 <body>
7 <script src="script-tests/class-list-gc.js"></script> 7 <script>
8 description('This tests that properties on the classList persists GC.');
9
10 function gc()
11 {
12 if (window.GCController)
13 return GCController.collect();
14
15 for (var i = 0; i < 10000; i++) {
16 var s = new String;
17 }
18 }
19
20 var d = document.createElement('div');
21
22 // Ensure the classList is created.
23 var classList = d.classList;
24
25 // Set a custom property.
26 d.classList.life = 42;
27 shouldEvaluateTo('d.classList.life', 42);
28
29 // Null out reference to the dataset.
30 classList = null;
31
32 gc();
33
34 // Test that the classList wrapper persisted the GC and still has the custom pro perty.
35 shouldEvaluateTo('d.classList.life', 42);
36 </script>
8 </body> 37 </body>
9 </html> 38 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698