From bc42d9e03aa3fde4e09ced66878e2dc61b490cf9 Mon Sep 17 00:00:00 2001 From: Zach Wasserman Date: Tue, 4 May 2021 16:18:09 -0700 Subject: [PATCH] Add waits in Teams e2e test (#721) Waits will hopefully further reduce flakiness. Add TODO for investigating possible bug in React code. --- cypress/integration/app/activateuser.spec.ts | 1 + cypress/integration/app/teamflow.spec.ts | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/cypress/integration/app/activateuser.spec.ts b/cypress/integration/app/activateuser.spec.ts index c13d1c8e56..b7f94b3774 100644 --- a/cypress/integration/app/activateuser.spec.ts +++ b/cypress/integration/app/activateuser.spec.ts @@ -18,6 +18,7 @@ describe("User invite and activation", () => { cy.findByRole("button", { name: /^create$/i }).click(); + // Ensure the email has been delivered cy.wait(3000); // eslint-disable-line cypress/no-unnecessary-waiting cy.logout(); diff --git a/cypress/integration/app/teamflow.spec.ts b/cypress/integration/app/teamflow.spec.ts index 9cb0903b1c..995bef87f3 100644 --- a/cypress/integration/app/teamflow.spec.ts +++ b/cypress/integration/app/teamflow.spec.ts @@ -17,6 +17,9 @@ describe("Teams flow", () => { cy.findByRole("button", { name: /^create$/i }).click(); cy.visit("/settings/teams"); + // Allow rendering to settle + // TODO this might represent a bug in the React code. + cy.wait(100); // eslint-disable-line cypress/no-unnecessary-waiting cy.contains("Valor").get(".Select-arrow-zone").click(); @@ -30,6 +33,9 @@ describe("Teams flow", () => { cy.findByRole("button", { name: /save/i }).click(); cy.visit("/settings/teams"); + // Allow rendering to settle + // TODO this might represent a bug in the React code. + cy.wait(100); // eslint-disable-line cypress/no-unnecessary-waiting cy.contains("Mystic").get(".Select-arrow-zone").click();