Issue
i tried to test this simple code
type Url = string
it('loads examples', () => {
const url: Url = 'https://www.ebay.com/'
cy.visit(url)
cy.get('input[type="text"]').type('book')
cy.get('#gh-btn').click();
})
then I faced this error
how can I solve it
Solution
the problem solved by adding this to support/index.js
import './commands'
Cypress.on('uncaught:exception', (err, runnable) => {
// returning false here prevents Cypress from
// failing the test
return false
})
this to avoid the uncaught : exception in
click()
Answered By - leen M

0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.