Skip to content

Fix flaky CI tests on Node.js 18: increase async assertion timeouts#14

Merged
bchr02 merged 3 commits into
masterfrom
copilot/fix-workflow-run-failure
Apr 30, 2026
Merged

Fix flaky CI tests on Node.js 18: increase async assertion timeouts#14
bchr02 merged 3 commits into
masterfrom
copilot/fix-workflow-run-failure

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 30, 2026

7 tests failed intermittently on the Node.js 18 CI job because assertion timers fired before atomic write operations (temp file write + rename) completed on a loaded runner. Node.js 20/22 passed consistently.

Changes

  • test/filejson.test.js — Increased assertion wait times for the 7 affected tests to provide adequate margin for async I/O under CI load:
Test Before After
should respect custom space configuration 100ms 300ms
should handle number values 100ms 300ms
should handle array values 100ms 300ms
should only save once after multiple rapid changes 200ms 400ms
should work with custom saveDelay of 200ms (late check) 150ms 400ms
should debounce with Promise API (late check) 100ms 200ms
should use atomic writes by default 100ms 300ms

Early "not-yet-saved" checks in debounce tests are unchanged — they still fire well within the saveDelay threshold.

@bchr02 bchr02 marked this pull request as ready for review April 30, 2026 21:12
@bchr02 bchr02 merged commit 64bb5e5 into master Apr 30, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants