Index: LayoutTests/fast/dom/shadow/shadow-tree-styles-select-host.html |
diff --git a/LayoutTests/fast/dom/shadow/shadow-tree-styles-select-host.html b/LayoutTests/fast/dom/shadow/shadow-tree-styles-select-host.html |
index 5fe188299cf0657a6a1bd84e083ef575a64adb85..184342a8775e81b59c40f5f268fa3f42dcc3a806 100644 |
--- a/LayoutTests/fast/dom/shadow/shadow-tree-styles-select-host.html |
+++ b/LayoutTests/fast/dom/shadow/shadow-tree-styles-select-host.html |
@@ -63,7 +63,7 @@ shouldHaveBorderColor('host-child', 'rgb(0, 0, 0)'); |
cleanUp(); |
-debug('Test that :not(*) in a shadow tree can match without :host.'); |
+debug('Test that :not(*) in a shadow tree cannot match without :host.'); |
sandbox.appendChild( |
createDOM('div', {'id': 'host'}, |
@@ -74,11 +74,26 @@ sandbox.appendChild( |
createDOM('div', {'id': 'host-child'}, |
document.createTextNode('Hello, Host!')))); |
-shouldHaveBorderColor('host', 'rgb(0, 128, 0)'); |
+shouldHaveBorderColor('host', 'rgb(0, 0, 0)'); |
shouldHaveBorderColor('host-child', 'rgb(0, 0, 0)'); |
cleanUp(); |
+debug('Test that :first-child in a shadow tree cannot match without :host.'); |
+ |
+sandbox.appendChild( |
+ createDOM('div', {'id': 'host'}, |
+ createShadowRoot( |
+ createDOM('style', {}, |
+ document.createTextNode(':first-child { border: 1px solid green; }')), |
+ createDOM('content', {})), |
+ createDOM('div', {'id': 'host-child'}, |
+ document.createTextNode('Hello, Host!')))); |
+ |
+shouldHaveBorderColor('host', 'rgb(0, 0, 0)'); |
+ |
+cleanUp(); |
+ |
debug('Test that styles in a containing treescope wins if specificities are the same.'); |
sandbox.appendChild( |