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

Side by Side Diff: LayoutTests/fast/dom/StyleSheet/gc-declaration-parent-rule.html

Issue 48903019: Delete js-test-post.js. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <style> 3 <style>
4 div { color:black } 4 div { color:black }
5 </style> 5 </style>
6 <script src="../../js/resources/js-test-pre.js"></script> 6 <script src="../../js/resources/js-test-pre.js"></script>
7 </head> 7 </head>
8 <body onload="test()"> 8 <body onload="test()">
9 <script> 9 <script>
10 window.jsTestIsAsync = true; 10 window.jsTestIsAsync = true;
11 description("Test that CSS rules don't lose custom properties on GC when only re achable through its declarations."); 11 description("Test that CSS rules don't lose custom properties on GC when only re achable through its declarations.");
12 12
13 function test() 13 function test()
14 { 14 {
15 var sheet = document.styleSheets[0]; 15 var sheet = document.styleSheets[0];
16 style = sheet.cssRules[0].style; 16 style = sheet.cssRules[0].style;
17 style.parentRule.foo = "bar"; 17 style.parentRule.foo = "bar";
18 document.getElementsByTagName("head")[0].removeChild(document.getElementsByT agName("style")[0]); 18 document.getElementsByTagName("head")[0].removeChild(document.getElementsByT agName("style")[0]);
19 sheet = null; 19 sheet = null;
20 20
21 gc(); 21 gc();
22 setTimeout(function() { 22 setTimeout(function() {
23 gc(); 23 gc();
24 shouldBe('style.parentRule.foo', '"bar"'); 24 shouldBe('style.parentRule.foo', '"bar"');
25 finishJSTest(); 25 finishJSTest();
26 }, 0); 26 }, 0);
27 } 27 }
28 </script> 28 </script>
29 <foo id="mystyle" style="display:none">.div { color: white; }</foo> 29 <foo id="mystyle" style="display:none">.div { color: white; }</foo>
30 <script src="../../js/resources/js-test-post.js"></script>
31 </body> 30 </body>
32 </html> 31 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698