phpunit/php-code-coverage 14.0 and PHPCOV 13.0 resolve long-standing issues with merging code coverage data from parallel CI jobs. The old format used absolute paths, causing failures when merging files from different machines. PHPUnit PHAR builds added internal namespace prefixes incompatible with Composer installs. Memory usage was also high due to loading all data into a single object. The new serialization format uses relative paths via a PathReducer, automatically strips PHAR namespace prefixes, and includes build metadata and optional Git state information. A new Merger class operates directly on serialized files rather than loading full CodeCoverage objects, reducing memory usage. PHPCOV 13.0's merge command now reliably combines .cov files from parallel CI jobs regardless of machine, directory structure, or PHPUnit installation method, outputting reports in Clover, Cobertura, HTML, and other formats.
Table of contents
The problem with mergingA new serialization formatA new mergerGit informationPHPCOVSummary9.5K Impressions1 Comment