Cypress - Overlay not popping up when button is clicked

622 views Asked by At

Description: I am currently trying to write an automated test that involves clicking on a button within a navigation bar. The expected behavior is that an overlay that contains more links would pop up, as seen in this video here: https://www.screencast.com/t/55vkmhY8msjt

When testing this manually within a Chrome browser (which is recorded in the aforementioned video), the overlay pops up as expected.

But when executing the automated Cypress test within the Cypress browser, Cypress is able to locate the element and successfully click it, but the overlay does not pop up. When I manually click on the button within the Cypress browser, the overlay does not pop up.

Video of bug being reproduced: https://www.screencast.com/t/iSn8suNHa It's hard to tell, but after the test execution finishes, I am manually trying to click on the button with my mouse.

I've tried several things:

cy.get(selector).click({force:true})
cy.get(selector).trigger('click')
cy.get(selector).invoke('click')

Extra information: This button was recently re-implemented using React Native's TouchableWithoutFeedback There are no errors being thrown in Cypress, no errors in the console.

Versions Cypress 7.5.0 Chrome Version 90.0.4430.93

Can somebody please suggest some other steps I can try?

0

There are 0 answers