Developer cuts test suite runtime from 96s to 41s by fixing three hidden bottlenecks
A developer working on a control-plane project traced a slow parallel test suite to three compounding issues: a database seeder running redundantly before every test, Xdebug silently applying coverage mode on all runs, and a test impact analysis tool repeatedly timing out before it could save a dependency graph. Fixes included moving the seeder to a per-process hook, pinning Xdebug to off mode via environment variables, and disabling Composer's process timeout while switching from Xdebug to pcov for coverage. Building pcov from source introduced an additional snag, as a static build produced a PHP extension with a missing symbol that mimicked an unrelated version-mismatch error. The changes brought the parallel suite from 96.2 seconds down to 41.1 seconds, with impact-analysis replays dropping to around 5 seconds, while all 1,451 tests continued to pass.
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