Closed
Description
Subject of the issue
A test will fails and throw ReferenceError: SVGElement is not defined
when calling isVisible()
on an SVG element.
Expected behaviour
Can correctly verify if an SVG Element is visible.
Actual behaviour
Throws an error when verifying if an SVG Element is visible.
Possible Solution
The issue was introduced here with the purpose to make isVisible
more comprehensive. This was ported from jest-dom as it is declared on the function comment but looking at js-dom repository they don't have instanceof SVGElement
but, instead instanceof window.SVGElement
which makes sense. Also, I have tried this fix and it worked so I will open PR with this suggested change and let you guys decide.
Metadata
Metadata
Assignees
Labels
No labels