Fix Blocker/Critical sonar issues
[aai/sparky-be.git] / pom.xml
diff --git a/pom.xml b/pom.xml
index 6e37aaa..388ec19 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -10,6 +10,7 @@
        <groupId>org.openecomp.aai.sparky-be</groupId>
        <artifactId>sparky-be</artifactId>
        <version>1.0-SNAPSHOT</version>
+       <name>aai-sparky-be</name>
 
        <properties>
                <docker.location>${basedir}/target</docker.location>
                <testEnv>DEV</testEnv>
                <checkstyle.config.location>google_checks.xml</checkstyle.config.location>
         <nexusproxy>https://nexus.onap.org</nexusproxy>
+        
+        <!-- Sonar Configuration -->
+        <sonar.language>java</sonar.language>
+       <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
+       <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
+       <sonar.jacoco.reportPath>${project.build.directory}/coverage-reports/jacoco.exec</sonar.jacoco.reportPath>
+       <sonar.jacoco.reportMissing.force.zero>false</sonar.jacoco.reportMissing.force.zero>
+       <sonar.projectVersion>${project.version}</sonar.projectVersion>
        </properties>
 
        <dependencies>
                        <plugin>
                                <groupId>org.jacoco</groupId>
                                <artifactId>jacoco-maven-plugin</artifactId>
-                               <version>0.7.9</version>
+                               <version>0.7.7.201606060606</version>
                                <configuration>
-                                       <destFile>${basedir}/target/coverage-reports/jacoco-unit.exec</destFile>
-                                       <dataFile>${basedir}/target/coverage-reports/jacoco-unit.exec</dataFile>
+                                       <dumpOnExit>true</dumpOnExit>
                                </configuration>
                                <executions>
                                        <execution>
-                                               <id>prepare-agent</id>
-                                               <goals>
-                                                       <goal>prepare-agent</goal>
-                                               </goals>
-                                       </execution>
-                                       <execution>
-                                               <id>jacoco-site</id>
-                                               <phase>package</phase>
-                                               <goals>
-                                                       <goal>report</goal>
-                                               </goals>
-                                       </execution>
+                                    <id>jacoco-initialize-unit-tests</id>
+                                    <goals>
+                                          <goal>prepare-agent</goal>
+                                    </goals>
+                                    <configuration>
+                                          <destFile>${project.build.directory}/coverage-reports/jacoco.exec</destFile>
+                                          <!-- <append>true</append> -->
+                                    </configuration>
+                                  </execution>
                                </executions>
                        </plugin>