Revert "Experiment: aggregate jacoco for sonar"
[yangtools.git] / yang / yang-data-impl / pom.xml
index 0a24c88201624290de976f84d748c42278d28596..3d8d4db14e1e60f0ac24a728169ce065257b7a71 100644 (file)
     <name>${project.artifactId}</name>
     <description>${project.artifactId}</description>
 
-    <properties>
-        <sonar.jacoco.reportPath>${project.basedir}/../../target/jacoco.exec</sonar.jacoco.reportPath>
-    </properties>
-
     <dependencyManagement>
         <dependencies>
             <dependency>
                 <artifactId>jacoco-maven-plugin</artifactId>
                 <executions>
                     <execution>
-                        <id>pre-unit-test</id>
+                        <id>prepare-ut-agent</id>
+                        <phase>process-test-classes</phase>
                         <goals>
                             <goal>prepare-agent</goal>
                         </goals>
                         <configuration>
-                            <destFile>${project.build.directory}/code-coverage/jacoco.exec</destFile>
+                            <destFile>${sonar.jacoco.reportPath}</destFile>
                             <propertyName>jacoco.agent.ut.arg</propertyName>
                         </configuration>
                     </execution>
-                    <execution>
-                        <id>post-unit-test</id>
-                        <goals>
-                            <goal>report</goal>
-                        </goals>
-                        <configuration>
-                            <dataFile>${project.build.directory}/code-coverage/jacoco.exec</dataFile>
-                        </configuration>
-                    </execution>
                     <execution>
                         <id>prepare-it-agent</id>
                         <phase>pre-integration-test</phase>
                             <goal>prepare-agent</goal>
                         </goals>
                         <configuration>
-                            <destFile>${project.build.directory}/code-coverage/jacoco-it.exec</destFile>
+                            <destFile>${sonar.jacoco.itReportPath}</destFile>
                             <propertyName>jacoco.agent.it.arg</propertyName>
                         </configuration>
                     </execution>