Upgrading a 3,000-file test suite from Vitest 4 to 5 cut test-step time by about 18%

A team moved its 3,000-file test suite from Vitest 4.1.8 to Vitest 5.0.4 and measured the results in CI. Timing only the test step across six full-suite runs, median time fell from 243 to 200 seconds, roughly 18% faster, close to the 19% the Vitest team published for a similar setup. The team cautions that six samples is too few for a firm conclusion, since the bootstrap interval for the change still includes zero. The migration required small fixes: unawaited resolves assertions now fail, mocks must live at module scope, and coverage counted ?? fallbacks as branches. The team estimates the speedup saves about 8 runner-hours a day, though per-pull-request wall-clock gains are around 2 minutes because browser tests were unchanged. The migration took about half a day, and the team plans a follow-up after a week of main-branch runs.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)
Log in to join the discussion and vote.
Log in