From 968c5bda7158e874bb248361e39d39f732996f7d Mon Sep 17 00:00:00 2001 From: Tim Donohue Date: Mon, 9 Sep 2024 16:21:03 -0500 Subject: [PATCH] Simplify login CSS selectors --- cypress/support/commands.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cypress/support/commands.ts b/cypress/support/commands.ts index b3e3b9630bb..8cc2c5c721b 100644 --- a/cypress/support/commands.ts +++ b/cypress/support/commands.ts @@ -101,11 +101,11 @@ Cypress.Commands.add('login', login); */ function loginViaForm(email: string, password: string): void { // Enter email - cy.get('ds-log-in [data-test="email"]').type(email); + cy.get('[data-test="email"]').type(email); // Enter password - cy.get('ds-log-in [data-test="password"]').type(password); + cy.get('[data-test="password"]').type(password); // Click login button - cy.get('ds-log-in [data-test="login-button"]').click(); + cy.get('[data-test="login-button"]').click(); } // Add as a Cypress command (i.e. assign to 'cy.loginViaForm') Cypress.Commands.add('loginViaForm', loginViaForm);