OLD | NEW |
| (Empty) |
1 <html> | |
2 <head> | |
3 <script src="../../resources/js-test.js"></script> | |
4 <script> | |
5 function runTest() | |
6 { | |
7 var targetDetails = document.getElementById("targetDetails"); | |
8 var clonedDetails = targetDetails.cloneNode(true); | |
9 document.body.appendChild(clonedDetails); | |
10 var targetSummary = document.getElementById("targetSummary"); | |
11 var clonedSummary = targetSummary.cloneNode(true); | |
12 targetDetails.appendChild(clonedSummary); | |
13 | |
14 if (!window.internals) | |
15 return; | |
16 | |
17 // On cloned <details>, marker shadow element should be created | |
18 var targetDetailsSummaryShadow = internals.shadowRoot(targetDetails.querySel
ector("summary")); | |
19 targetMarkerPseudoId = internals.shadowPseudoId(targetDetailsSummaryShadow.f
irstChild); | |
20 var clonedDetailsSummaryShadow = internals.shadowRoot(clonedDetails.querySel
ector("summary")); | |
21 clonedMarkerPseudoId = internals.shadowPseudoId(clonedDetailsSummaryShadow.f
irstChild); | |
22 shouldBe("targetMarkerPseudoId", "clonedMarkerPseudoId"); | |
23 } | |
24 </script> | |
25 <body onload="runTest()"> | |
26 <p id="description">Test to clone details and summary elements</p> | |
27 <div id="console"></div> | |
28 <details id="targetDetails" open> | |
29 <summary id="targetSummary"></summary> | |
30 </details> | |
31 </body> | |
32 </html> | |
OLD | NEW |