Fix error about coverage
[vfc/nfvo/driver/sfc.git] / zte / sfc-driver / sfc-driver / pom.xml
index 41d01d2..dbf1e74 100644 (file)
         <swagger.version>1.5.3</swagger.version>
         <junit.version>4.11</junit.version>
         <powermock.version>1.6.6</powermock.version>
+        <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
+        <sonar.coverage.jacoco.xmlReportPaths>${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
+        <sonar.jacoco.reportMissing.force.zero>true</sonar.jacoco.reportMissing.force.zero>
+        <sonar.projectVersion>${project.version}</sonar.projectVersion>
+        <sonar.dynamicAnalysis>reuseReports</sonar.dynamicAnalysis>
     </properties>
 
 
              </execution>  
          </executions>
      </plugin>
+            <plugin>
+                <groupId>org.jacoco</groupId>
+                <artifactId>jacoco-maven-plugin</artifactId>
+                <executions>
+                  <execution>
+                    <id>prepare-agent</id>
+                    <goals>
+                        <goal>prepare-agent</goal>
+                    </goals>
+                  </execution>
+                  <execution>
+                     <id>report</id>
+                     <goals>
+                       <goal>report</goal>
+                     </goals>
+                     <configuration>
+                        <dataFile>${project.build.directory}/code-coverage/jacoco.exec</dataFile>
+                        <outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</outputDirectory>
+                     </configuration>
+                  </execution>
+               </executions>
+            </plugin>
         </plugins>
     </build>
 </project>