diff --git a/shadow-dom/declarative/declarative-shadow-dom-attachment.html b/shadow-dom/declarative/declarative-shadow-dom-attachment.html index 6fb2a8a5ecc30f..aec9a276f931f0 100644 --- a/shadow-dom/declarative/declarative-shadow-dom-attachment.html +++ b/shadow-dom/declarative/declarative-shadow-dom-attachment.html @@ -42,9 +42,13 @@ originalShadowRoot = element.shadowRoot; } - // Now, call attachShadow() and make sure we get back the same (original) shadowRoot, but empty. const oppositeMode = (mode === 'open') ? 'closed' : 'open'; - const newShadow = element.attachShadow({mode: oppositeMode}); // Should be no exception here + assert_throws_dom('NotSupportedError', () => { + element.attachShadow({mode: oppositeMode}); + }, 'Calling attachShadow with a declarative shadow fails if the mode doesn\'t match'); + + // Now, call attachShadow() and make sure we get back the same (original) shadowRoot, but empty. + const newShadow = element.attachShadow({mode: mode, delegatesFocus: delegatesFocus}); if (mode === 'open') { assert_equals(element.shadowRoot, originalShadowRoot, 'The same shadow root should be returned'); assert_equals(element.shadowRoot.innerHTML, '', 'Empty shadow content'); diff --git a/shadow-dom/declarative/declarative-shadow-dom-basic.html b/shadow-dom/declarative/declarative-shadow-dom-basic.html index 20ca34f6f3e259..8799978804a53b 100644 --- a/shadow-dom/declarative/declarative-shadow-dom-basic.html +++ b/shadow-dom/declarative/declarative-shadow-dom-basic.html @@ -154,10 +154,14 @@ diff --git a/shadow-dom/declarative/declarative-shadow-dom-repeats.html b/shadow-dom/declarative/declarative-shadow-dom-repeats.html new file mode 100644 index 00000000000000..3da9cff360c64d --- /dev/null +++ b/shadow-dom/declarative/declarative-shadow-dom-repeats.html @@ -0,0 +1,73 @@ + +Declarative Shadow DOM Element Attachment + + + + + + + + + + +
+ + +
+ +
+ + +
+ + + +
+ +
+ + + +
+ +
+ +