From 12a0e727587501e95138edaf02587187c15eceed Mon Sep 17 00:00:00 2001 From: Paul Campbell Date: Tue, 30 May 2017 20:52:29 +0100 Subject: [PATCH 1/2] travis-ci: deploy master even when a pull request --- travis-ci/travis-deploy.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/travis-ci/travis-deploy.sh b/travis-ci/travis-deploy.sh index af7f714..e01a265 100755 --- a/travis-ci/travis-deploy.sh +++ b/travis-ci/travis-deploy.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash -if [ "$TRAVIS_BRANCH" = 'master' ] && [ "$TRAVIS_PULL_REQUEST" == 'false' ]; then +if [ "$TRAVIS_BRANCH" = 'master' ]; then echo "Preparing to deploy to nexus..." openssl aes-256-cbc -K $encrypted_f424d6efdd6f_key -iv $encrypted_f424d6efdd6f_iv \ -in travis-ci/codesigning.asc.enc -out travis-ci/codesigning.asc -d From f9997db8f6a50aac99acdd593332999245a9a54b Mon Sep 17 00:00:00 2001 From: Paul Campbell Date: Tue, 30 May 2017 21:22:27 +0100 Subject: [PATCH 2/2] pom.xml: enable pitest mutation testing plugin --- README.md | 42 +++++++++++++++++++++++++++++++++++++++++- pom.xml | 39 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 80 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 08ea14f..a8ab584 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,7 @@ desired value. * huntbugs.version * jacoco-maven-plugin.version * highwheel-maven.version +* pitest.version * maven-jxr-plugin.version * jacoco-class-line-covered-ratio * jacoco-class-instruction-covered-ratio @@ -197,7 +198,46 @@ classes. ### Configuration -The plugin will `analyse` the project during the `compile` phase. +The plugin will `analyse` the project during the `verify` phase. + +## Pitest Plugin + +The [Pitest Plugin](http://pitest.org/) +provides mutation testing for classes found in the generated `target` +directory. + +### Configuration + +The plugin with perform mutation tests during the `verify` phase. + +By default, classed named `Immutable*`, will not be included. +(e.g. classes generated by `org.immutables:value`) + +The following properties can adjust the default configuration. + +#### `pitest.skip` + +Default is `false`. + +Set this to `true` to disable the **Pitest Plugin**. + +#### `pitest.coverage` + +Default is `0`%. (i.e. disabled) + +Line coverage at which to fail build. + +#### `pitest.mutation` + +Default is `0`%. (i.e. disabled) + +Mutation score threshold at which to fail build. + +#### `pitest.failWhenNoMutations` + +Default is `true`. + +Set this to `false` to not fail build when there are no mutations. ## Digraph Dependency Plugin diff --git a/pom.xml b/pom.xml index 22e7042..abc995a 100644 --- a/pom.xml +++ b/pom.xml @@ -60,12 +60,17 @@ 0.0.11 0.7.9 1.2 + 1.2.0 2.5 0.50 0.80 0 1.8 + 0 + 0 + false + true @@ -361,6 +366,28 @@ + + + org.pitest + pitest-maven + ${pitest.version} + + + verify + + mutationCoverage + + + + + ${pitest.skip} + false + *.Immutable* + ${pitest.coverage} + ${pitest.mutation} + ${pitest.failWhenNoMutations} + + @@ -390,6 +417,18 @@ true + + org.pitest + pitest-maven + ${pitest.version} + + + + report + + + +