Skip to end of metadata
Go to start of metadata

Overview

It is possible to feed SonarQube with tests execution and code coverage reports.

See Component Viewer on Unit Test File or Quality Flows > Lack of Unit Tests to browse the results in the web interface.

Usage

To be reused by SonarQube:

  • The tests execution reports have to comply to the JUnit XML format.
  • The code coverage reports have to be generated by JaCoCoCobertura or Clover.

You can check the page of each coverage plugin to get more information on how to generate the reports or you can check the Analyzing with Maven documentation.

JaCoCo, Surefire and "argLine"

Icon

If you use JaCoCo and define argLine in Surefire configuration, please check JaCoCo plugin page for a note on the best usage.

 

You can set the following properties to import those reports:

Project samples are available on github that can be browsed or downloadedprojects/languages/java/code-coverage/ut


  • No labels