[test] Fix flaky file-system-cache-clock tests (#100946)
The tests added in PR #100357 can race background fetch-cache writes after the HTTP response completes. The tests now wait for the expected value and `lastModified` timestamp on disk before checking cache reuse, stopping the server, or inspecting the rewritten entry. The first request after tag revalidation must still return fresh data without retries. [Flakiness metrics](https://app.datadoghq.com/ci/ci-cd/explorer/executions?query=test_level%3Atest%20%40git.repository.id%3A%22github.com%2Fvercel%2Fnext.js%22%20%40test.name%3A%22file-system-cache-clock%20with%20the%20default%20memory%20cache%20reads%20a%20fetch%20cache%20entry%20written%20without%20a%20stored%20timestamp%22%20%40test.type%3A%22turbopack%22%20%40test.status%3A%22fail%22&agg_m=count&agg_m_source=base&agg_t=count&ci_cd_explorer_tab=tests&fromUser=false&start=1792744453308&end=1793349253308&paused=false)
Showing
Please
register
or
sign in
to comment