Angular Cypress.io test with Google Login popup window

Discussão em 'Angular' iniciado por beachCode, Janeiro 22, 2025.

  1. beachCode

    beachCode Guest

    Is it possible to login to a Google account with Cypress.io using the Google authentication pop-up window?

    I can get the window to open, but then Cypress can't detect the ID for the email input field.

    The error is: "CypressError: Timed out retrying: Expected to find element: '#identifierId', but never found it."

    it('Login', function() {
    cy.visit('home')
    cy.get('#signin-button').click()
    cy.get('#google-login-button').click()
    // cy.wait(1500) // wait doesn't help
    cy.get('#identifierId')
    .type('user@gmail.com') // <<-- error here
    })

    Continue reading...

Compartilhe esta Página