I want to check the type of element found with an id. I'm using an asserton with instanceof matcher, but it's failing.
My test is as follows:
cy.get('#calculated').should(($el) => {
expect($el[0]).to.be.instanceof(HTMLDivElement)
})
My HTML is
<div id="calculated">123.40</div>
Clearly the element is a div, so what is wrong with the assertion syntax?