CSS.supports undefined #1166
Unanswered
WebMechanic
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I'm a bit confused...
It seems
CSS.ts
implements the CSS interface, however ...the snippet below is some bit from a Vitest (0.34.6) test case with "@vitest-environment happy-dom" and
@happy-dom/global-registrator
set, loaded and enabled.I need to test a script that makes calls to
CSS.supports()
which fails with "supports is not a function". I'm not interested in any results of CSS.supports() but the test suite won't execute load bc. of "supports" miraculously being undefined.Why does
window.CSS
pass butCSS.supports
is reported to be "undefined" andCSS.supports("fubar")
fails with "supports is not a function"?What am I missing here?
The script to be tested runs "flawless" in a real browser but has no test coverage because of this weirness.
Thanks 4 help.
Beta Was this translation helpful? Give feedback.
All reactions