Use odlparent configuration for jacoco 03/26303/2
authorThanh Ha <thanh.ha@linuxfoundation.org>
Wed, 2 Sep 2015 03:46:13 +0000 (23:46 -0400)
committerMichal Polkorab <michal.polkorab@pantheon.sk>
Wed, 30 Sep 2015 13:44:53 +0000 (13:44 +0000)
Change-Id: I2825a7637eb95e085cbeeb3286e468362c3545b9
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
parent/pom.xml

index 8cff79012c79e6b5efef617732fd2f9f4b0f5c3a..e7b1ea4f32f9c1b380bad325842a2284988c6386 100644 (file)
         <config.version>0.4.0-SNAPSHOT</config.version>
         <mdsal.version>1.3.0-SNAPSHOT</mdsal.version>
         <yangtools.version>0.8.0-SNAPSHOT</yangtools.version>
-
-        <!-- Sonar config -->
-        <sonar-jacoco-listeners.version>2.4</sonar-jacoco-listeners.version>
-        <sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
-        <sonar.jacoco.reportPath>target/code-coverage/jacoco.exec</sonar.jacoco.reportPath>
-        <sonar.jacoco.itReportPath>target/code-coverage/jacoco-it.exec</sonar.jacoco.itReportPath>
     </properties>
 
     <dependencyManagement>
         </dependencies>
     </dependencyManagement>
 
-    <dependencies>
-        <!-- Sonar -->
-        <dependency>
-            <groupId>org.codehaus.sonar-plugins.java</groupId>
-            <artifactId>sonar-jacoco-listeners</artifactId>
-            <version>${sonar-jacoco-listeners.version}</version>
-            <scope>test</scope>
-        </dependency>
-    </dependencies>
-
     <build>
         <plugins>
             <plugin>
                 <groupId>org.codehaus.mojo</groupId>
                 <artifactId>build-helper-maven-plugin</artifactId>
             </plugin>
-            <plugin>
-                <groupId>org.jacoco</groupId>
-                <artifactId>jacoco-maven-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <id>prepare-ut-agent</id>
-                        <phase>process-test-classes</phase>
-                        <goals>
-                            <goal>prepare-agent</goal>
-                        </goals>
-                        <configuration>
-                            <destFile>${sonar.jacoco.reportPath}</destFile>
-                            <propertyName>jacoco.agent.ut.arg</propertyName>
-                        </configuration>
-                    </execution>
-                    <execution>
-                        <id>prepare-it-agent</id>
-                        <phase>pre-integration-test</phase>
-                        <goals>
-                            <goal>prepare-agent</goal>
-                        </goals>
-                        <configuration>
-                            <destFile>${sonar.jacoco.itReportPath}</destFile>
-                            <propertyName>jacoco.agent.it.arg</propertyName>
-                        </configuration>
-                    </execution>
-                </executions>
-            </plugin>
         </plugins>
         <pluginManagement>
             <plugins>
                         </execution>
                     </executions>
                 </plugin>
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-failsafe-plugin</artifactId>
-                    <configuration>
-                        <!-- Specific to generate mapping between tests and covered code -->
-                        <argLine>${jacoco.agent.it.arg}</argLine>
-                        <properties>
-                            <property>
-                                <name>listener</name>
-                                <value>org.sonar.java.jacoco.JUnitListener</value>
-                            </property>
-                        </properties>
-                        <!-- Let's put failsafe reports with surefire to have access to tests failures/success reports in sonar -->
-                        <reportsDirectory>${project.build.directory}/surefire-reports</reportsDirectory>
-                    </configuration>
-                </plugin>
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-surefire-plugin</artifactId>
-                    <configuration>
-                        <!-- Specific to generate mapping between tests and covered code -->
-                        <argLine>${jacoco.agent.ut.arg}</argLine>
-                        <properties>
-                            <property>
-                                <name>listener</name>
-                                <value>org.sonar.java.jacoco.JUnitListener</value>
-                            </property>
-                        </properties>
-                    </configuration>
-                </plugin>
                 <!-- Ignore/Execute plugin execution -->
                 <plugin>
                   <groupId>org.eclipse.m2e</groupId>