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

Side by Side Diff: LayoutTests/fast/dom/shadow/content-pseudo-element-in-inert-shadow.html

Issue 210953003: Make style independent of the presence of the <shadow> element. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | LayoutTests/fast/dom/shadow/content-pseudo-element-in-inert-shadow-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <script src="resources/shadow-dom.js"></script>
5 <script src="../../../resources/js-test.js"></script>
6 </head>
7 <body>
8 <div id="sandbox"></div>
9 <script>
10 var borderColor;
11
12 function borderColorOf(node)
13 {
14 return document.defaultView.getComputedStyle(node, null).getPropertyValue('b order-color');
15 }
16
17 function borderColorShouldNotBe(selector, color)
18 {
19 var text = 'borderColorOf(getNodeInTreeOfTrees("' + selector + '"))';
20 var unevaledString = '"' + color.replace(/\\/g, "\\\\").replace(/"/g, "\"") + '"';
21 shouldNotBe(text, unevaledString);
22 }
23
24 function cleanUp()
25 {
26 document.getElementById('sandbox').innerHTML = '';
27 }
28
29 description('crbug.com/341372: Test for rules with ::content declared in inert s hadow trees');
30
31 var sandbox = document.getElementById('sandbox');
32 sandbox.appendChild(
33 createDOM('div', {'id': 'host'},
34 createShadowRoot(
35 createDOM('style', {},
36 document.createTextNode('content::content div { border: 1px soli d red; }'),
37 createDOM('div', {},
38 document.createTextNode('inert')))),
39 createShadowRoot(
40 createDOM('content')),
41 createDOM('div', {'id': 'target'},
42 document.createTextNode('no border'))));
43
44 borderColorShouldNotBe('target', 'rgb(255, 0, 0)');
45
46 cleanUp();
47 </script>
48 </body>
49 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/dom/shadow/content-pseudo-element-in-inert-shadow-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698