Skip to content

Commit 97f88ba

Browse files
[Shadow DOM tests] Skip tests in not supported browsers (#123)
1 parent f00a60e commit 97f88ba

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tests/shadow.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
import StyleObserver from "../index.js";
22
import gentleRegisterProperty from "./util/gentle-register-property.js";
33
import tests from "./tests.js";
4+
import bugs from "../src/util/detect-bugs.js";
45

56
const inlineStyleTest = {
67
name: "Don't use inline styles",
8+
skip: !document.adoptedStyleSheets || bugs.ADOPTED_STYLE_SHEET,
79
async run ({property, meta, initial, value}) {
810
// Make the property unique
911
property += "-" + this.data.hostId;
@@ -127,6 +129,7 @@ export default {
127129
},
128130
{
129131
name: "Declarative",
132+
skip: document.getElementById("declarative-host").shadowRoot === null,
130133
data: {
131134
hostId: "declarative-host",
132135
},

0 commit comments

Comments
 (0)