I'm trying to automate a page within an application that has two buttons on a page. One is enabled and can be clicked. The other is disabled on the first load. But once the first button is pressed, a tab new browser tab is opened and then the second button is enabled. Then the user can click that and go onto a form.
Obviously Cypress can't be handling new tabs, but is there a way I can invoke the click command without actually calling the event through a click?
I have tried cy.get(".button1").trigger("click")
but a new tab is still opened.
One solution I guess is to break it into two tests. But is there a better way?