test(testing): raise waitForText poll default 5000→10000ms to de-flake render tests - #120
Merged
Merged
Conversation
…ke render tests The vitest gate flaked a 2nd time — screenshot.test.ts "preserves 256-color codes" timed out after 5000ms waiting for ORANGE. #116 raised VITEST's testTimeout (15000ms), but the real 5000ms is waitForText's OWN internal poll timeout (src/testing/session.ts), which #116 never touched — so terminal render under CI load still tripped it. Raise the waitForText/waitForAbsent/waitFor default to 10000ms, matching the explicit 10000-15000ms render-heavy tests already pass (scrollback-fidelity.test.ts) and staying under screenshot's 15000ms vitest testTimeout. Only affects failure/slow-wait latency; a matching wait returns immediately. Folded into this PR so it fixes BOTH required-gate flakes (parity teardown ENOTEMPTY + screenshot render timeout) and one CI run validates both.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Raise
waitForTextpoll default 5000→10000ms to de-flake render testsThe required vitest gate flaked on
screenshot.test.ts > preserves 256-color codes— timed out at 5000ms waiting for text. (This is the still-open flakeafter #119; my fix raced #119's merge and didn't make it in, so re-submitting.)
Why #116 didn't fix it: #116 raised vitest's
testTimeoutto 15000ms, butthe real 5000ms is
waitForText's own internal poll timeout(
src/testing/session.ts), which #116 never touched. So #116 fixed thetrue-color flake's symptom (the blunt vitest test-timeout) but left the
underlying too-tight render-poll budget — which resurfaced as the 256-color
waitForTexttimeout.Fix: raise the
waitForText/waitForAbsent/waitFordefault5000→10000ms, matching the explicit 10000–15000ms that render-heavy tests
already pass (
scrollback-fidelity.test.ts) and staying underscreenshot.test.ts's 15000ms vitesttestTimeout, so a slow wait fails withthe useful "waiting for X" message rather than a blunt vitest timeout. Only
affects failure/slow-wait latency; a matching wait returns immediately.
Verification: render suites green locally (49 tests), full suite green,
typecheck clean. The CI-load timing can't be reproduced locally, but 10000ms is
2× the budget that tripped. Test-support-library default only; no product
behavior change. (Verified green in the #119 fresh CI run before that PR merged
parity-only.)