devnix / clover-uncovered-lines
A tool to extract uncovered lines from Clover code coverage reports.
Installs: 1
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/devnix/clover-uncovered-lines
Requires
- php: ^8.4
Requires (Dev)
- ergebnis/composer-normalize: ^2.48
- friendsofphp/php-cs-fixer: ^3.88
- infection/infection: ^0.32.2
- phpstan/extension-installer: ^1.4
- phpstan/phpstan: ^2.1
- phpstan/phpstan-deprecation-rules: ^2.0
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-strict-rules: ^2.0
- phpunit/phpunit: ^12.4
- rector/rector: ^2.2
- symfony/var-dumper: ^7.3
- symplify/phpstan-rules: ^14.8
README
A simple CLI tool to parse Clover XML coverage reports and display uncovered lines in a human(-and-llm)-readable format.
Installation
Install via Composer:
composer require --dev devnix/clover-uncovered-lines
Usage
Run the tool by passing the path to your Clover XML coverage file:
vendor/bin/clover-uncovered-lines path/to/clover.xml
Example Output
When there are uncovered lines:
Uncovered lines:
src/Example.php
Lines 15-18
Line 42 (method)
src/AnotherFile.php
Line 23
Summary: 5 uncovered lines in 2 file(s)
When all lines are covered:
✓ All lines are covered!
Exit Codes
0- All lines are covered1- Uncovered lines found or error occurred
Features
- Parses Clover XML coverage reports
- Groups consecutive uncovered lines into ranges for readability
- Identifies uncovered methods
- Auto-detects project root from XML paths
- Provides summary statistics
Requirements
- PHP 8.4 or higher
License
MIT
Author
Pablo Largo Mohedano (devnix.code@gmail.com)