![Build status](https://github.com/wmaarts/pitest-mutation-testing-elements-plugin/workflows/CI/badge.svg)
pitest-mutation-testing-elements-plugin
A pitest plugin that maps pitest results to stryker's mutation-testing-elements.
How to use 💁
- Add the dependency to the pitest plugin
- Configure the outputFormat to be one of
Maven
Add the dependency and configure the outputFormat
to use the plugin:
<plugin>
<groupId>org.pitest</groupId>
<artifactId>pitest-maven</artifactId>
<version>1.4.10</version>
<dependencies>
<dependency>
<groupId>io.github.wmaarts</groupId>
<artifactId>pitest-mutation-testing-elements-plugin</artifactId>
<version>${pitest-mutation-testing-elements-plugin.version}</version>
</dependency>
</dependencies>
<configuration>
<outputFormats>
<format>HTML2</format>
<format>JSON</format>
</outputFormats>
</configuration>
</plugin>
Run like you would normally run pitest: ▶
mvn org.pitest:pitest-maven:mutationCoverage
Gradle
Follow the setup for the gradle-pitest-plugin, then add the plugin as a pitest dependency in your build.gradle
:
buildscript {
repositories {
mavenCentral()
}
configurations.maybeCreate('pitest')
dependencies {
classpath 'info.solidsoft.gradle.pitest:gradle-pitest-plugin:1.4.7'
pitest 'io.github.wmaarts:pitest-mutation-testing-elements-plugin:${pluginVersion}'
}
}
And configure the output format:
apply plugin: 'info.solidsoft.pitest'
pitest {
outputFormats = ['HTML2', 'JSON']
}
Preview 🔮
This is a result of pitest run on this plugin. (More previews here)
![preview](https://user-images.githubusercontent.com/10114577/217536203-2148ebe0-bd71-4132-8123-39e1eca58f52.png)