Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Arquillian Jacoco Extension
Java

ARQ-1967 Add configuration property 'appendAsmLibrary' with default=t…

…rue.

Setting 'appendAsmLibrary' to 'false' overcomes issues of frameworks
using server-side ASM library, e.g. Apache CXF.

Otherwise you might face class incompatibility exception, e.g.:
ERROR [org.jboss.msc.service.fail] (MSC service thread 1-1) MSC000001:
Failed to start service
jboss.deployment.unit."7aa60fe5-e3e8-4e00-935f-ab80d2bb42b1.war".INSTALL:
org.jboss.msc.service.StartException in service
jboss.deployment.unit."7aa60fe5-e3e8-4e00-935f-ab80d2bb42b1.war".INSTALL:
JBAS018733: Verarbeitung von Phase INSTALL von deployment
        ...
	... 5 more
Caused by: java.lang.reflect.UndeclaredThrowableException
	at
org.apache.cxf.common.util.ReflectionInvokationHandler.invoke(ReflectionInvokationHandler.java:85)
	... 28 more

Signed-off-by: Andreas Weise <andreas.weise@gmail.com>
latest commit 885dfd463f
@catandgrep catandgrep authored aslakknutsen committed

README.asciidoc

Arquillian Jacoco Extension

Automagic Remote InContainer Codecoverage

Usage

Maven pom.xml

Add the following to your pom.xml:

Set the versions to use:

...
<properties>
   <version.jacoco>0.7.4.201502262128</version.jacoco>
   <version.arquillian_jacoco>1.0.0.Alpha8</version.arquillian_jacoco>
</properties>
...

Configure the Jacoco Maven plugin and depend on the Arquillian Jacoco Extension:

...
<profile>
   <id>jacoco</id>
   <dependencies>
      <dependency>
         <groupId>org.jacoco</groupId>
         <artifactId>org.jacoco.core</artifactId>
         <version>${version.jacoco}</version>
         <scope>test</scope>
      </dependency>
      <dependency>
         <groupId>org.jboss.arquillian.extension</groupId>
         <artifactId>arquillian-jacoco</artifactId>
         <version>${version.arquillian_jacoco}</version>
         <scope>test</scope>
      </dependency>
   </dependencies>
   <build>
      <plugins>
         <plugin>
            <groupId>org.jacoco</groupId>
            <artifactId>jacoco-maven-plugin</artifactId>
            <version>${version.jacoco}</version>
            <executions>
               <execution>
                  <goals>
                     <goal>prepare-agent</goal>
                  </goals>
               </execution>
               <execution>
                  <id>report</id>
                  <phase>prepare-package</phase>
                  <goals>
                     <goal>report</goal>
                  </goals>
               </execution>
            </executions>
         </plugin>
      </plugins>
   </build>
</profile>

Activate this profile on command line by using the -P flag:

mvn test -Pjacoco

Sonar

When using the Arquillian Jacoco Extension with Sonar you only need to depend on the Arquillian Jacoco Extension. Sonar will handle the setup of Jacoco for you.

Something went wrong with that request. Please try again.