You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2020/01/09 16:07:04 UTC

[syncope] branch master updated: Fixing default JaCoCo / Sonar settings

This is an automated email from the ASF dual-hosted git repository.

ilgrosso pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/syncope.git


The following commit(s) were added to refs/heads/master by this push:
     new 856198d  Fixing default JaCoCo / Sonar settings
856198d is described below

commit 856198d6e96373b6cb8a828dd6f9a64770f7bd08
Author: Francesco Chicchiriccò <il...@apache.org>
AuthorDate: Thu Jan 9 16:20:06 2020 +0100

    Fixing default JaCoCo / Sonar settings
---
 pom.xml | 45 ++++++++++++++++++++-------------------------
 1 file changed, 20 insertions(+), 25 deletions(-)

diff --git a/pom.xml b/pom.xml
index 5fa666d..b7c7463 100644
--- a/pom.xml
+++ b/pom.xml
@@ -548,13 +548,12 @@ under the License.
 
     <ianal.skip>false</ianal.skip>
     <skip.sass>false</skip.sass>
-    <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
-    <sonar.jacoco.utReportPath>${rootpom.basedir}/target/jacoco.ut.exec</sonar.jacoco.utReportPath>
-    <sonar.jacoco.itReportPath>${rootpom.basedir}/target/jacoco.it.exec</sonar.jacoco.itReportPath>
-    <sonar.jacoco.reportPaths>${sonar.jacoco.utReportPath},${sonar.jacoco.itReportPath}</sonar.jacoco.reportPaths>
-    <sonar.junit.reportPaths>${project.build.directory}/surefire-reports,${project.build.directory}/failsafe-reports</sonar.junit.reportPaths>
+
     <sonar.language>java</sonar.language>
     <sonar.java.source>${targetJdk}</sonar.java.source>
+    <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
+    <sonar.junit.reportPaths>${project.build.directory}/surefire-reports</sonar.junit.reportPaths>
+    <sonar.coverage.jacoco.xmlReportPaths>target/site/jacoco/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
 
     <targetJdk>11</targetJdk>
     <rootpom.basedir>${basedir}</rootpom.basedir>
@@ -2145,6 +2144,18 @@ under the License.
           <artifactId>sass-maven-plugin</artifactId>
           <version>3.7.2</version>
         </plugin>
+
+        <plugin>
+          <groupId>org.jacoco</groupId>
+          <artifactId>jacoco-maven-plugin</artifactId>
+          <version>0.8.5</version>
+        </plugin>
+
+        <plugin>
+          <groupId>org.sonarsource.scanner.maven</groupId>
+          <artifactId>sonar-maven-plugin</artifactId>
+          <version>3.7.0.1746</version>
+        </plugin>
       </plugins>
     </pluginManagement>
 
@@ -2214,37 +2225,21 @@ under the License.
       <plugin>
         <groupId>org.jacoco</groupId>
         <artifactId>jacoco-maven-plugin</artifactId>
-        <version>0.8.5</version>
         <configuration>
-          <append>true</append>
           <skip>${skipTests}</skip>
         </configuration>
         <executions>
           <execution>
-            <id>jacoco-agent-ut</id>
-            <phase>process-test-classes</phase>
+            <id>prepare-jacoco-agent</id>
             <goals>
               <goal>prepare-agent</goal>
             </goals>
-            <configuration>
-              <destFile>${sonar.jacoco.utReportPath}</destFile>
-            </configuration>
           </execution>
           <execution>
-            <id>jacoco-agent-it</id>
-            <phase>pre-integration-test</phase>
-            <goals>
-              <goal>prepare-agent-integration</goal>
-            </goals>
-            <configuration>
-              <destFile>${sonar.jacoco.itReportPath}</destFile>
-            </configuration>
-          </execution>
-          <execution>
-            <id>jacoco-site</id>
-            <phase>verify</phase>
+            <id>generate-code-coverage-report</id>
+            <phase>test</phase>
             <goals>
-              <goal>report-aggregate</goal>
+              <goal>report</goal>
             </goals>
           </execution>
         </executions>