Skip to content

Commit

Permalink
aggregate jacoco reports in distribution module
Browse files Browse the repository at this point in the history
- declare distribution (non-source-) dependencies top-level (this allows
  to use the distribution artifact as a 'bill of materials' dependency)
- specify jacoco exclusions in central location (build parent)
- use jacoco's aggregate feature to correctly calculate coverage cross-module
- configure coveralls plugin accordingly
  • Loading branch information
mtf90 committed Nov 19, 2017
1 parent 5988e2c commit adb045c
Show file tree
Hide file tree
Showing 12 changed files with 219 additions and 311 deletions.
17 changes: 0 additions & 17 deletions algorithms/active/adt/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,6 @@ limitations under the License.
<name>LearnLib :: Algorithms :: ADT</name>
<description>The ADT Algorithm</description>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/ADTLearnerBuilder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<!-- LearnLib dependencies -->
<dependency>
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/dhc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,23 +32,6 @@ limitations under the License.
<name>LearnLib :: Algorithms :: DHC</name>
<description>The Direct Hypothesis Construction algorithm for active learning of Mealy machines</description>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/MealyDHCBuilder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<!--
Compile-time dependencies
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/discrimination-tree-vpda/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,6 @@ limitations under the License.
<artifactId>learnlib-discrimination-tree-vpda</artifactId>
<name>LearnLib :: Algorithms :: Discrimination Tree [VPDA]</name>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/DTLearnerVPDABuilder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<dependency>
<groupId>de.learnlib</groupId>
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/discrimination-tree/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,6 @@ limitations under the License.
<artifactId>learnlib-discrimination-tree</artifactId>
<name>LearnLib :: Algorithms :: Discrimination Tree</name>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/DTLearner*Builder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<dependency>
<groupId>de.learnlib</groupId>
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/kearns-vazirani/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,23 +29,6 @@ limitations under the License.
<name>LearnLib :: Algorithms :: Kearns/Vazirani</name>
<description>The automata learning algorithm described by Kearns &amp; Vazirani</description>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/KearnsVazirani*Builder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<dependency>
<groupId>de.learnlib</groupId>
Expand Down
20 changes: 0 additions & 20 deletions algorithms/active/lstar/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,26 +35,6 @@ limitations under the License.
proposed by e.g. Maler &amp; Pnueli and Rivest &amp; Schapire).
</description>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/ClassicLStar*Builder.class</exclude>
<exclude>**/ExtensibleLStar*Builder.class</exclude>
<exclude>**/MalerPnueli*Builder.class</exclude>
<exclude>**/RivestSchapire*Builder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<!--
Compile-time dependencies
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/nlstar/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,6 @@ limitations under the License.
<name>LearnLib :: Algorithms :: NL*</name>
<artifactId>learnlib-nlstar</artifactId>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/NLStarLearnerBuilder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<dependency>
<groupId>de.learnlib</groupId>
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/ttt-vpda/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,23 +32,6 @@ limitations under the License.
<name>LearnLib :: Algorithms :: TTT [VPDA]</name>
<description>The TTT Algorithm</description>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/TTTLearnerVPDABuilder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<!--
Compile-time dependencies
Expand Down
17 changes: 0 additions & 17 deletions algorithms/active/ttt/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,23 +32,6 @@ limitations under the License.
<name>LearnLib :: Algorithms :: TTT</name>
<description>The TTT Algorithm</description>

<build>
<pluginManagement>
<plugins>
<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/TTTLearner*Builder.class</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<dependencies>
<!--
Compile-time dependencies
Expand Down
24 changes: 24 additions & 0 deletions build-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,30 @@ limitations under the License.
<build>
<pluginManagement>
<plugins>

<!-- If we run coverage analysis, skip generated sources -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<configuration>
<excludes>
<!-- generated builders for learning algorithms -->
<exclude>**/ADTLearnerBuilder.class</exclude>
<exclude>**/MealyDHCBuilder.class</exclude>
<exclude>**/DTLearner*Builder.class</exclude>
<exclude>**/DTLearnerVPDABuilder.class</exclude>
<exclude>**/KearnsVazirani*Builder.class</exclude>
<exclude>**/ClassicLStar*Builder.class</exclude>
<exclude>**/ExtensibleLStar*Builder.class</exclude>
<exclude>**/MalerPnueli*Builder.class</exclude>
<exclude>**/RivestSchapire*Builder.class</exclude>
<exclude>**/NLStarLearnerBuilder.class</exclude>
<exclude>**/TTTLearner*Builder.class</exclude>
<exclude>**/TTTLearnerVPDABuilder.class</exclude>
</excludes>
</configuration>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-pmd-plugin</artifactId>
Expand Down

0 comments on commit adb045c

Please sign in to comment.