Bug 40809 - JS warning should make Cypress tests fail
Summary: JS warning should make Cypress tests fail
Status: Needs Signoff
Alias: None
Product: Koha
Classification: Unclassified
Component: Test Suite (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low enhancement
Assignee: Jonathan Druart
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-09-15 12:22 UTC by Jonathan Druart
Modified: 2025-09-15 12:50 UTC (History)
1 user (show)

See Also:
GIT URL:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 40809: Fail Cypress tests on JS warnings (1.23 KB, patch)
2025-09-15 12:25 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Druart 2025-09-15 12:22:57 UTC

    
Comment 1 Jonathan Druart 2025-09-15 12:25:42 UTC
Created attachment 186401 [details] [review]
Bug 40809: Fail Cypress tests on JS warnings

Currently JS warnings during Cypress tests are ignored.
This change intercepts console warnings in the browser and if any occurs
the test failed

This helps catch potential issues and ensures that warnings are not
silently ignored during test runs.
Comment 2 Jonathan Druart 2025-09-15 12:50:22 UTC
Test plan:
All Cypress tests should still pass.

QA will take care of adding a JS warning and confirm that the test fails.