From 1b006820bd5d886053d4eeef3947940986c6752d Mon Sep 17 00:00:00 2001 From: Oliver Eyton-Williams Date: Wed, 1 Dec 2021 20:12:09 +0100 Subject: [PATCH] fix(tests): wait longer for login to complete (#44349) Hopefully this is long enough. If it isn't, we'll need to find out why login takes so long. --- cypress/support/commands.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cypress/support/commands.js b/cypress/support/commands.js index 50a139436cd..af020d1e21d 100644 --- a/cypress/support/commands.js +++ b/cypress/support/commands.js @@ -35,7 +35,7 @@ Cypress.Commands.add('login', () => { cy.visit('/'); cy.contains("Get started (it's free)").click(); - cy.location().should(loc => { + cy.location({ timeout: 10000 }).should(loc => { // I'm not 100% sure why logins get redirected to /learn/ via 301 in // development, but not in production, but they do. Hence to make it easier // work on tests, we'll just allow for both.