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

Unified Diff: LayoutTests/fast/dom/StyleSheet/gc-parent-rule.html

Issue 238303004: Remove DOMImplementation.createCSSStyleSheet() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: update tests Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/fast/dom/StyleSheet/gc-parent-rule-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/dom/StyleSheet/gc-parent-rule.html
diff --git a/LayoutTests/fast/dom/StyleSheet/gc-parent-rule.html b/LayoutTests/fast/dom/StyleSheet/gc-parent-rule.html
index 20337410897123a29a8f4ebb47882f1a72daf4b1..3a8d5b629679f22d7a66beb0f4e35d934ad27c01 100644
--- a/LayoutTests/fast/dom/StyleSheet/gc-parent-rule.html
+++ b/LayoutTests/fast/dom/StyleSheet/gc-parent-rule.html
@@ -7,9 +7,20 @@
window.jsTestIsAsync = true;
description("Test that CSS rules don't lose custom properties on GC when only reachable through child rules.");
+function createCSSStyleSheet()
+{
+ style = document.createElement("style");
+ document.head.appendChild(style);
+ shouldBeType("style.sheet", "CSSStyleSheet");
+ var sheet = style.sheet;
+ document.head.removeChild(style);
+ shouldBeNull("style.sheet");
+ return sheet;
+}
+
function test()
{
- var sheet = document.implementation.createCSSStyleSheet("title", "screen");
+ var sheet = createCSSStyleSheet();
sheet.insertRule("@media all { div { color:black } }", 0);
rule = sheet.rules[0].cssRules[0];
rule.parentRule.foo = "bar";
« no previous file with comments | « no previous file | LayoutTests/fast/dom/StyleSheet/gc-parent-rule-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698