nimut/phpunit-merger
Composer 安装命令:
composer require nimut/phpunit-merger
包简介
Merge multiple PHPUnit reports into one file
README 文档
README
Sometimes it is necessary to run multiple PHPUnit instances to execute all tests of a project. Unfortunately each run writes its own coverage and log reports. There is no support in PHPUnit to merge the reports of multiple runs.
This project provides two commands to merge coverage files as well as log files. It was designed to provide merged reports to e.g. SonarQube Scanner for further processing.
Installation
Use Composer to install the testing framework.
$ composer require --dev nimut/phpunit-merger
Composer will add the package as a dev requirement to your composer.json and install the package with its dependencies.
Usage
Coverage
The coverage command merges files containing PHP_CodeCoverage objects into one file in Clover XML format.
$ vendor/bin/phpunit-merger coverage <directory> [--html=<directory>] [<file>]
Arguments
directory: Directory containing one or multiple files with PHP_CodeCoverage objectsfile: File where the merged result should be stored. Default: Standard output
Options
html: Directory where the HTML report should be storedlowUpperBound: (optional) The lowUpperBound value to be used for HTML formathighLowerBound: (optional) The highLowerBound value to be used for HTML format
Log
The log command merges files in JUnit XML format into one file in JUnit XML format.
$ vendor/bin/phpunit-merger log <directory> <file>
Arguments
directory: Provides the directory containing one or multiple files in JUnit XML formatfile: File where the merged result should be stored
nimut/phpunit-merger 适用场景与选型建议
nimut/phpunit-merger 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 1.81M 次下载、GitHub Stars 达 50, 最近一次更新时间为 2017 年 12 月 17 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「phpunit」 「coverage」 「TYPO3 CMS」 「sonarqube」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 nimut/phpunit-merger 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 nimut/phpunit-merger 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 nimut/phpunit-merger 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
PHP client library for Coveralls API
HiDev plugin for PHPUnit
Testing Suite For Lumen like Laravel does.
A helper for PHPUnit 7 to generate code coverage under PHP 8
A cli tool which generates unit tests.
Check a project's code coverage, optionally enforcing a minimum value
统计信息
- 总下载量: 1.81M
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 51
- 点击次数: 25
- 依赖项目数: 6
- 推荐数: 0
其他信息
- 授权协议: GPL-2.0
- 更新时间: 2017-12-17