Created
February 12, 2012 18:06
-
-
Save shyiko/1809954 to your computer and use it in GitHub Desktop.
Sonar & JaCoCo & Maven 3 integration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<project ...> | |
... | |
<properties> | |
<sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin> | |
<sonar.dynamicAnalysis>reuseReports</sonar.dynamicAnalysis> | |
<sonar.jacoco.reportPath>${user.dir}/target/jacoco.exec</sonar.jacoco.reportPath> | |
</properties> | |
... | |
<build> | |
<plugins> | |
<plugin> | |
<groupId>org.codehaus.mojo</groupId> | |
<artifactId>sonar-maven-plugin</artifactId> | |
<version>2.0</version> | |
</plugin> | |
<plugin> | |
<groupId>org.jacoco</groupId> | |
<artifactId>jacoco-maven-plugin</artifactId> | |
<version>0.5.6.201201232323</version> | |
<configuration> | |
<destFile>${session.executionRootDirectory}/target/jacoco.exec</destFile> | |
</configuration> | |
<executions> | |
<execution> | |
<goals> | |
<goal>prepare-agent</goal> | |
</goals> | |
<phase>initialize</phase> | |
</execution> | |
</executions> | |
</plugin> | |
</plugins> | |
</build> | |
</project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
mvn clean test sonar:sonar