Skip to content

Commit

Permalink
Adding wait for the "work" request to prevent testing prematurely
Browse files Browse the repository at this point in the history
  • Loading branch information
clausbruun committed Apr 3, 2024
1 parent 7a9ef46 commit fc92941
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/apps/fee-list/fee-list.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,10 @@ describe("Fee list", () => {
}).as("work");

cy.visit("/iframe.html?path=/story/apps-fee-list--fee-list-entry");
cy.wait(["@fees"]);
cy.wait(["@work"]);
});

it("Fee list basics (physical loans)", () => {
// Wait for the full page to load, ensuring we don't test on the skeleton screen, by waiting for an element that isn't present in the skeleton.
cy.getBySel("list-reservation__about").should("be.visible");

// 2. System shows:
// 2.a. Headline "Fees & Replacement costs"
cy.getBySel("fee-list-page")
Expand Down

0 comments on commit fc92941

Please sign in to comment.