You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I am using happy-dom with vitest and I noticed after upgrading to antd@5.1.2 A bunch of my unit tests are failing with:
this error:
TypeError: Right-hand side of 'instanceof' is not an object
❯ _default node_modules/.pnpm/rc-util@5.27.1_biqbaboplfbrettd7655fr4n2y/node_modules/rc-util/lib/Dom/isVisible.js:14:15
At first I thought this was a bug in rc-util a library used by antd. But upon further inspection, it seems like it's a missing feature/case in happy-dom
The part that is causing the error using happy-dom is element instanceof SVGGraphicsElement. If I comment out this if statement all of my unit tests will pass without issues.
To Reproduce
Steps to reproduce the behavior:
Create a file that uses instanceof SVGGraphicsElement
Run it in a test environment using happy-dom@8.4.3
See error
Expected behavior
parsing instanceof SVGGraphicsElement should not cause an error.
Device:
OS: MacOS
Browser: node
Version: "happy-dom": "8.4.3",
Temporary solution
For now I have switched back to use JSdom where this problem does not occur. Will set up happy-dom again once this issue is resolved.
The text was updated successfully, but these errors were encountered:
Describe the bug
I am using happy-dom with vitest and I noticed after upgrading to antd@5.1.2 A bunch of my unit tests are failing with:
this error:
At first I thought this was a bug in
rc-util
a library used byantd
. But upon further inspection, it seems like it's a missing feature/case inhappy-dom
This is the file that causes the error:
The part that is causing the error using happy-dom is
element instanceof SVGGraphicsElement
. If I comment out this if statement all of my unit tests will pass without issues.To Reproduce
Steps to reproduce the behavior:
instanceof SVGGraphicsElement
happy-dom@8.4.3
Expected behavior
parsing
instanceof SVGGraphicsElement
should not cause an error.Device:
Temporary solution
For now I have switched back to use
JSdom
where this problem does not occur. Will set up happy-dom again once this issue is resolved.The text was updated successfully, but these errors were encountered: