...

/

Main E2E Test Defects: Determinism

Main E2E Test Defects: Determinism

Make Cypress tests more deterministic by randomizing a user.

We'll cover the following...

Introduction

Recalling the signup flow E2E test:

context("Signup flow", () => {
  it("The happy path should work", () => {
    cy.visit("/register");
    cy.get(".form-control").then($els => {
      cy.get($els[0]).type("Tester");
      cy.get($els[1]).type("user@realworld.io");
      cy.get($els[2]).type("mysupersecretpassword");
    });
    cy.get("button").click();
   
...