Bug 40051

Summary: cy.wait(delay) should not be used in Cypress tests
Product: Koha Reporter: Jonathan Druart <jonathan.druart>
Component: Test SuiteAssignee: Jonathan Druart <jonathan.druart>
Status: BLOCKED --- QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: pedro.amorim
Version: unspecified   
Hardware: All   
OS: All   
GIT URL: Change sponsored?: ---
Patch complexity: --- Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on: 40046    
Bug Blocks:    
Attachments: Bug 40051: Remove cy.wait(delay) from cypress tests

Description Jonathan Druart 2025-06-02 11:49:22 UTC
It can cause random failures. We should rely on the existence of something, Cypress will retry if the test fails.
Comment 1 Jonathan Druart 2025-06-02 11:54:02 UTC
Created attachment 182905 [details] [review]
Bug 40051: Remove cy.wait(delay) from cypress tests

We should not use cy.wait(delay), it's a poor pattern and can cause
random failures.

Test plan:
All cypress tests should still pass after this patchset.

Note that t/cypress/integration/ERM/Titles_spec.ts is currently failing.
Comment 2 Jonathan Druart 2025-06-02 11:55:18 UTC
I've asked Pedro to have a look at Titles_spec.ts.