https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40383 --- Comment #58 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Created attachment 199479 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=199479&action=edit Bug 40383: (follow-up) Fix EdifactModal Cypress test reliability Three fixes to make all 27 EdifactModal Cypress tests reliably pass: 1. insertData.js: fix currency FK constraint violation (use an existing currency rather than creating an undefined one). 2. Koha/Edifact/File.pm: add missing use statements for File::Basename and File::Temp so the Cypress task can load the module. 3. EdifactModal_spec.ts: - Replace arbitrary cy.wait() calls with condition-based assertions throughout (expand/collapse animations, Bootstrap modal state). - Fix search timing: add cy.intercept + cy.wait("@ediMsg") in the Search Functionality beforeEach so initializeSearch is wired before input events fire; use invoke("val")+trigger("input") instead of type() to bypass the 500ms debounce race. - Fix modal close tests: attach a shown.bs.modal listener before opening the modal so we can wait for Bootstrap's 300ms show animation to complete (_isTransitioning → false) before calling hide(). Without this wait, hide() is silently blocked when the Ajax response is faster than the animation (common in KTD). Use bootstrap.Modal.getInstance().hide() as the programmatic fallback since data-bs-dismiss and keyboard events are unreliable in headless Cypress/Electron. - Fix edifact_interchange.js: remove duplicate &format=json appended to URLs that already contain it. -- You are receiving this mail because: You are watching all bug changes.