Skip to content

Commit

Permalink
add jacoco in pom.xml
Browse files Browse the repository at this point in the history
  • Loading branch information
cicciu committed Apr 15, 2021
1 parent fa2de41 commit fb28a9e
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@
<sonar.java.target>${java.version}</sonar.java.target>
<sonar.organization>osirix-foundation-1</sonar.organization>
<sonar.projectKey>karnak</sonar.projectKey>
<jacoco-maven-plugin.version>0.8.6</jacoco-maven-plugin.version>
<sonar-maven-plugin.version>3.8.0.2131</sonar-maven-plugin.version>
<sonar.coverage.jacoco.xmlReportPaths>${project.basedir}/target/site/jacoco/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
<sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
<h2.version>1.4.200</h2.version>
</properties>

Expand Down Expand Up @@ -228,6 +232,40 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco-maven-plugin.version}</version>
<configuration>
<append>true</append>
</configuration>
<executions>
<execution>
<id>prepare-agent</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>prepare-agent-integration</id>
<goals>
<goal>prepare-agent-integration</goal>
</goals>
</execution>
<execution>
<id>jacoco-site</id>
<phase>verify</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.sonarsource.scanner.maven</groupId>
<artifactId>sonar-maven-plugin</artifactId>
<version>${sonar-maven-plugin.version}</version>
</plugin>
</plugins>
<resources>
<resource>
Expand All @@ -240,6 +278,25 @@
</resources>
</build>

<!-- Reportings -->
<reporting>
<plugins>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco-maven-plugin.version}</version>
<reportSets>
<reportSet>
<reports>
<!-- select non-aggregate reports -->
<report>report</report>
</reports>
</reportSet>
</reportSets>
</plugin>
</plugins>
</reporting>

<!-- Dependencies -->
<dependencies>
<dependency>
Expand Down

0 comments on commit fb28a9e

Please sign in to comment.