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

Unified Diff: LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text.html

Issue 212383002: Drop empty list :host() and :host-context(). (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 9 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/shadow/host-context-pseudo-class-css-text-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text.html
diff --git a/LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text.html b/LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text.html
new file mode 100644
index 0000000000000000000000000000000000000000..a542d4e0613ff3ca587e07e75a53581cef9c6b53
--- /dev/null
+++ b/LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text.html
@@ -0,0 +1,24 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src="../../../resources/js-test.js"></script>
+<style id="style1">
+.foo:host-context(div, body.mytheme, p#myid, .bar::before, span:hover) > div { display: block; }
+:host-context(*) { display: block; }
+</style>
+<style id="style-invalid">
+:host-context(div div) { display: block }
+:host-context(div > div) { display: block }
+:host-context(div + div) { display: block }
+:host-context(div ~ div) { display: block }
+:host-context) { display: block }
+:host-context() { display: block; }
+</style>
+</head>
+<script>
+description("Test for cssText of ':host-context()' rule.");
+shouldBeEqualToString("document.getElementById('style1').sheet.cssRules.item(0).cssText", ".foo:host-context(div,body.mytheme,p#myid,.bar::before,span:hover) > div { display: block; }");
+shouldBeEqualToString("document.getElementById('style1').sheet.cssRules.item(1).cssText", ":host-context(*) { display: block; }");
+shouldBe("document.getElementById('style-invalid').sheet.cssRules.length", "0");
+</script>
+</html>
« no previous file with comments | « no previous file | LayoutTests/fast/dom/shadow/host-context-pseudo-class-css-text-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698