Skip to content

Instantly share code, notes, and snippets.

@rainerhahnekamp
Created August 3, 2021 08:34
Show Gist options
  • Save rainerhahnekamp/25e59d339d432efb7b914324e3427625 to your computer and use it in GitHub Desktop.
Save rainerhahnekamp/25e59d339d432efb7b914324e3427625 to your computer and use it in GitHub Desktop.
it('should click on add customers', () => {
cy.visit('')
.then(() => cy.get('[data-test=btn-customers]'))
.then((button) => button.click())
.then(() => cy.get('[data-test=btn-customers-add]'))
.then((button) => button.click());
});
it('should click on add customers', async () => {
await cy.visit('');
const button = await cy.get('[data-test=btn-customers]');
await button.click();
const button2 = await cy.get('[data-test=btn-customers-add]');
await button2.click();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment