Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The goal of this plugin is to bring PIT results to SonarQube. Right now the integration of these results is quite simple, "survived mutants" on code covered by tests are seen as SonarQubeissuesSonarQube issues.  

Info
titleNote
Even if PIT detects "survived mutants" on uncovered lines of code, these mutants are simply ignored by the plugin.

...

  • Mutation testing is very CPU time expensive. It is really important to control the scope of mutation testing in order to keep acceptable SonarQubeanalysis SonarQube analysis times. See below for tips on analysis time.
  • Mutation testing works on true unit tests. Do not try to use it on integration tests, you might mess up your database, file system, whatever external system used by your integration tests. 

...

Last but not least, you need to run a SonarQube analysis with the PIT plugin activated in "reuseReport" mode. The following command would do the job :
"mvn sonar:sonar -Dsonar.pitest.mode=reuseReport"

By default SonarQubewill SonarQube will search the latest PIT report in "target/pit-reports". You can specify another location using property "sonar.pitest.reportsDirectory".

...