Files
msd-core/tests
0xdhx 3d2cb1fb01 test(#4850): read freshness under the fixture git timeout in derivationIsNotMemoizedAcrossRenders (#4870)
The row asserts that deriveStateFreshness is not memoized across renders,
and it did so through the hook's real git spawn bounded by the 1500 ms
production timeout. On a loaded Windows runner the second spawn can exceed
that bound, and readStateHeadCommits returns its designed null, which the
exact-count assertion reads as a failure (null !== 10).

Wrap the two freshness reads in the block's existing withSpawnSpy, forwarding
to the real execFileSync with the fixture-scoped GIT_FIXTURE_TIMEOUT_MS in
place of the production bound. The spawn stays real, so a genuine memoization
regression (second read returning 5) still fails the row. No production file
changes; STATE_FRESHNESS_GIT_TIMEOUT_MS stays 1500.

Closes #4850

Co-authored-by: Tom Boucher <trekkie@nomorestars.com>
2026-09-20 01:19:07 -04:00
..