OLD | NEW |
---|---|
(Empty) | |
1 <!DOCTYPE html> | |
2 <script src='../resources/testharness.js'></script> | |
3 <script src='../resources/testharnessreport.js'></script> | |
4 <script src="resources/shadow-dom.js"></script> | |
5 <div id="x"><span></span></div> | |
6 <div id="x"><span></span></div> | |
7 <div id="host"> | |
8 <template data-mode='open'> | |
9 <div id="y"><span></span></div> | |
10 <div id="y"><span></span></div> | |
11 </template> | |
12 </div> | |
13 <script> | |
14 convertTemplatesToShadowRootsWithin(host); | |
15 test(() => { | |
16 assert_equals(document.querySelectorAll('#x').length, 2); | |
17 assert_equals(document.querySelectorAll('#x span').length, 2); | |
18 }, "querySelectorAll for multiple #Ids in a document tree"); | |
19 | |
20 test(() => { | |
21 assert_equals(host.shadowRoot.querySelectorAll('#y').length, 2); | |
22 assert_equals(host.shadowRoot.querySelectorAll('#y span').length, 2); | |
23 }, "querySelectorAll for multiple #Ids in a shadow tree"); | |
kochi
2016/04/15 05:31:25
style nit: consistent usage of single and double q
hayato
2016/04/15 05:34:06
Done. Made it consistent.
| |
24 </script> | |
OLD | NEW |