Hi,
it is not possible to merge already generated coverage reports.
But you can (re-)create a coverage report based on execution data from
multiple runs. There are multiple ways to do this:
* Merge multiple exec files into a single one (see merge goal)
* Create the report with multiple exec files as input
* Let the JaCoCo agent append exec data to a single file (this is how
you already configured your agent)
However it is not possible to merge execution data when class files have
been changed between the individual test runs.
Regards,
-marc
On 25.08.17 12:10, [email protected] wrote:
How to append existing coverage report in new coverage report
Hi All,
I am working on application, where after every 2 hours we need to update the
build means need to replace ROOT.war in tomcat/webapps.
Is there any way append existing report in new coverage report.
Changes in POM.xml:
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.7.9</version>
<configuration>
<skip>${maven.test.skip}</skip>
<!--<output>file</output> -->
<append>true</append>
</configuration>
<executions>
<execution>
<id>jacoco-initialize</id>
<goals>
<goal>prepare-agent</goal>
</goals>
<configuration>
<!-- Sets the path to the file which contains
the execution data. -->
<destFile>${project.build.directory}/target/jacoco.exec</destFile>
</configuration>
</execution>
<execution>
<id>jacoco-site</id>
<phase>verify</phase>
<goals>
<goal>report</goal>
</goals>
<configuration>
<!-- Sets the path to the file which contains
the execution data. -->
<destFile>${project.build.directory}/target/jacoco.exec</destFile>
</configuration>
</execution>
</executions>
</plugin>
Changes in Catlina.sh: set JAVA_OPTS=%JAVA_OPTS% %LOGGING_MANAGER%
-javaagent:D:\jacoco-0.7.9\lib\jacocoagent.jar=destfile=D:\jacoco\jacoco.exec,append=true,includes=*,output=file
Please suggest if there is any way to do that
--
You received this message because you are subscribed to the Google Groups "JaCoCo
and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jacoco/4f4a009c-a1da-117f-73da-a47e0ac52160%40mountainminds.com.
For more options, visit https://groups.google.com/d/optout.