GithubHelp home page GithubHelp logo

phpunit-merger's Introduction

Merge multiple PHPUnit reports into one file

Latest Stable Version StyleCI

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 objects
  • file: File where the merged result should be stored. Default: Standard output

Options

  • html: Directory where the HTML report should be stored
  • lowUpperBound: (optional) The lowUpperBound value to be used for HTML format
  • highLowerBound: (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 format
  • file: File where the merged result should be stored

phpunit-merger's People

Contributors

carlos-granados avatar denizsokullu avatar eimers avatar ichhabrecht avatar tomasnorre avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.