Empty aggregate-report results?

1,096 views
Skip to first unread message

Kevin S. Clarke

unread,
Aug 24, 2016, 10:36:34 AM8/24/16
to JaCoCo and EclEmma Users
I have a build configured that produces unit and integration reports as two separate exec files. I need to aggregate those so that I can send the complete results to an online service. I've updated my POM to use the latest version of the jacoco-maven-plugin so that I can run the report-aggregate goal. It looks like things are being processed in the correct order:

[INFO] 
[INFO] --- maven-failsafe-plugin:2.17:verify (default) @ vertx-pairtree ---
[INFO] Failsafe report directory: /home/kevin/Workspace/vertx-pairtree/target/failsafe-reports
[INFO] 
[INFO] --- jacoco-maven-plugin:0.7.7.201606060606:report (default-report) @ vertx-pairtree ---
[INFO] Loading execution data file /home/kevin/Workspace/vertx-pairtree/target/jacoco-ut.exec
[INFO] Analyzed bundle 'Vert.x Pairtree' with 16 classes
[INFO] 
[INFO] --- jacoco-maven-plugin:0.7.7.201606060606:report-integration (default-report-integration) @ vertx-pairtree ---
[INFO] Loading execution data file /home/kevin/Workspace/vertx-pairtree/target/jacoco-it.exec
[INFO] Analyzed bundle 'Vert.x Pairtree' with 16 classes
[INFO] 
[INFO] --- jacoco-maven-plugin:0.7.7.201606060606:report-aggregate (report-aggregate) @ vertx-pairtree ---
[INFO] Loading execution data file /home/kevin/Workspace/vertx-pairtree/target/jacoco-ut.exec
[INFO] Loading execution data file /home/kevin/Workspace/vertx-pairtree/target/jacoco-it.exec
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------

but the jacoco-aggregate directory ends up with an empty report:

  target/site/jacoco:
    index.html  info.freelibrary.pairtree  info.freelibrary.pairtree.fs  info.freelibrary.pairtree.s3  jacoco.csv  jacoco-resources  jacoco-sessions.html  jacoco.xml

  target/site/jacoco-aggregate:
    index.html  jacoco.csv  jacoco-resources  jacoco-sessions.html  jacoco.xml

  target/site/jacoco-it:
    index.html  info.freelibrary.pairtree  info.freelibrary.pairtree.fs  info.freelibrary.pairtree.s3  jacoco.csv  jacoco-resources  jacoco-sessions.html  jacoco.xml

My configuration of the plugin uses the defaults and is done in a Maven profile that is configured to run the integration tests first (the rest of the plugin executions configuration is done outside of the profile):

          <plugin>
            <groupId>org.jacoco</groupId>
            <artifactId>jacoco-maven-plugin</artifactId>
            <executions>
              <execution>
                <id>report-aggregate</id>
                <phase>verify</phase>
                <goals>
                  <goal>report-aggregate</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

The ouput (above) says it loads the *.exec files but I don't understand why the report would be essentially empty:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE report PUBLIC "-//JACOCO//DTD Report 1.0//EN" "report.dtd">
<report name="Vert.x Pairtree">
  <sessioninfo id="kevin-oryx-19414da7" start="1472048817404" dump="1472048819240"/>
  <sessioninfo id="kevin-oryx-d0d1ee1f" start="1472048820120" dump="1472048837955"/>
</report>

Anyone have any hints on what might be going wrong?

Thanks,
Kevin

Marc Hoffmann

unread,
Aug 24, 2016, 11:32:07 AM8/24/16
to jac...@googlegroups.com
Hi,

aggregate-report "Creates a structured code coverage report (HTML, XML,
and CSV) from multiple projects within reactor." In particular the
project itself is not contained in the report
(http://www.eclemma.org/jacoco/trunk/doc/report-aggregate-mojo.html)

If I understand you correctly you want to combine different test runs
within the same project, right? Please check our merge goal for this
case.

Regards,
-marc
> --
> 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 jacoco+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com
> [1].
> For more options, visit https://groups.google.com/d/optout.
>
>
> Links:
> ------
> [1]
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com?utm_medium=email&utm_source=footer

Kevin S. Clarke

unread,
Aug 24, 2016, 11:37:03 AM8/24/16
to jac...@googlegroups.com
Yes, thanks. I misunderstood the purpose of aggregate-report, I guess. I've looked at merge before but, if my understanding is correct, that's only for exec output right? I need the XML output to submit to this service (Codacy). Is there a way to go from the merged exec file to an XML formatted version?

Thanks,
Kevin



--
You received this message because you are subscribed to a topic in the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jacoco+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/7e5e2ade112d8b11c943ae6cdea7bbfd%40mountainminds.com.

For more options, visit https://groups.google.com/d/optout.



--
"There are two kinds of people in this world: those who believe there are two kinds of people in this world and those who know better."

Marc Hoffmann

unread,
Aug 24, 2016, 11:40:04 AM8/24/16
to jac...@googlegroups.com
Here is the workflow:

- Run Tests 1 and configure it to create exec1
- Run Tests 2 and configure it to create exec2
- Merge exec1 and exec2 to execAll
- Create the xml report with execAll

Does this make sense?

Regards,
-marc



On 2016-08-24 17:36, Kevin S. Clarke wrote:
> Yes, thanks. I misunderstood the purpose of aggregate-report, I guess.
> I've looked at merge before but, if my understanding is correct,
> that's only for exec output right? I need the XML output to submit to
> this service (Codacy). Is there a way to go from the merged exec file
> to an XML formatted version?
>
> Thanks,
> Kevin
>
> On Wed, Aug 24, 2016 at 11:32 AM, Marc Hoffmann
> <hoff...@mountainminds.com> wrote:
>
>> Hi,
>>
>> aggregate-report "Creates a structured code coverage report (HTML,
>> XML, and CSV) from multiple projects within reactor." In particular
>> the project itself is not contained in the report
>> (http://www.eclemma.org/jacoco/trunk/doc/report-aggregate-mojo.html
>> [4])
>>> an email to jacoco+un...@googlegroups.com.
>>> To view this discussion on the web visit
>>>
>>
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com
>>> [1]
>>> [1].
>>> For more options, visit https://groups.google.com/d/optout [2].
>>> [3]
>>
>> --
>> You received this message because you are subscribed to a topic in
>> the Google Groups "JaCoCo and EclEmma Users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe
>> [5].
>> To unsubscribe from this group and all its topics, send an email to
>> jacoco+un...@googlegroups.com.
>> To view this discussion on the web visit
>>
> https://groups.google.com/d/msgid/jacoco/7e5e2ade112d8b11c943ae6cdea7bbfd%40mountainminds.com
>> [6].
>> For more options, visit https://groups.google.com/d/optout [2].
>
> --
> "There are two kinds of people in this world: those who believe there
> are two kinds of people in this world and those who know better."
>
> --
> 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 jacoco+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jacoco/CAE6YT8QASCFDrc62O-g%3D9SwEUrgBhVnmJ%3DX1zDfkLM%3DS-T9fBw%40mail.gmail.com
> [7].
> [2] https://groups.google.com/d/optout
> [3]
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [4] http://www.eclemma.org/jacoco/trunk/doc/report-aggregate-mojo.html
> [5] https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe
> [6]
> https://groups.google.com/d/msgid/jacoco/7e5e2ade112d8b11c943ae6cdea7bbfd%40mountainminds.com
> [7]
> https://groups.google.com/d/msgid/jacoco/CAE6YT8QASCFDrc62O-g%3D9SwEUrgBhVnmJ%3DX1zDfkLM%3DS-T9fBw%40mail.gmail.com?utm_medium=email&utm_source=footer

Kevin S. Clarke

unread,
Aug 24, 2016, 11:44:40 AM8/24/16
to jac...@googlegroups.com
Yes, I just don't know how to do step 4. But I assuming from your response that it's in the documentation and I've just missed it so I'll return there.

Thanks for the help,
Kevin



To view this discussion on the web visit

[3]

--
You received this message because you are subscribed to a topic in
the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe
[5].

To unsubscribe from this group and all its topics, send an email to

To view this discussion on the web visit

https://groups.google.com/d/msgid/jacoco/7e5e2ade112d8b11c943ae6cdea7bbfd%40mountainminds.com
[6].
For more options, visit https://groups.google.com/d/optout [2].

--
"There are two kinds of people in this world: those who believe there
are two kinds of people in this world and those who know better."

 --
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

To view this discussion on the web visit
--
You received this message because you are subscribed to a topic in the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jacoco+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/09433a19aef31bc6d6eaf8041ba5c150%40mountainminds.com.

For more options, visit https://groups.google.com/d/optout.

Kevin S. Clarke

unread,
Aug 24, 2016, 11:51:22 AM8/24/16
to jac...@googlegroups.com
Oh, okay, I'll just need to configure another report execution (or run it from a CI script).

Thanks,
Kevin

Marc Hoffmann

unread,
Aug 24, 2016, 12:04:08 PM8/24/16
to jac...@googlegroups.com
Just one report generation on "execAll" is enough. Just configure the
report goal to point it to the correct exec file. If call the merged
exec file jacoco.exec this is default anyways. Here is documentation for
the report goal:

http://www.eclemma.org/jacoco/trunk/doc/report-mojo.html

Let me know whether this works for you!

Regards,
-marc
>> [1]
>>> an email to jacoco+un...@googlegroups.com.
> [4]
> [5]
>
>>> [3]
>>
>> --
>> You received this message because you are subscribed to a topic in
>> the Google Groups "JaCoCo and EclEmma Users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe [3]
>> [5].
>> To unsubscribe from this group and all its topics, send an email to
>> jacoco+un...@googlegroups.com.
>> To view this discussion on the web visit
>
> https://groups.google.com/d/msgid/jacoco/7e5e2ade112d8b11c943ae6cdea7bbfd%40mountainminds.com
> [6]
>
>> [6].
>> For more options, visit https://groups.google.com/d/optout [2] [2].
>
> --
> "There are two kinds of people in this world: those who believe there
> are two kinds of people in this world and those who know better."
>
> --
> 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 jacoco+un...@googlegroups.com.
> [4]
> [2] https://groups.google.com/d/optout [2]
> [3]
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [8]
> [4] http://www.eclemma.org/jacoco/trunk/doc/report-aggregate-mojo.html
> [1]
> [5] https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe
> [3]
> [6]
> https://groups.google.com/d/msgid/jacoco/7e5e2ade112d8b11c943ae6cdea7bbfd%40mountainminds.com
> [6]
> [7]
> https://groups.google.com/d/msgid/jacoco/CAE6YT8QASCFDrc62O-g%3D9SwEUrgBhVnmJ%3DX1zDfkLM%3DS-T9fBw%40mail.gmail.com?utm_medium=email&utm_source=footer
> [9]
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "JaCoCo and EclEmma Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe [3].
> To unsubscribe from this group and all its topics, send an email to
> jacoco+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jacoco/09433a19aef31bc6d6eaf8041ba5c150%40mountainminds.com
> [10].
>
> For more options, visit https://groups.google.com/d/optout [2].
>
> --
> "There are two kinds of people in this world: those who believe there
> are two kinds of people in this world and those who know better."
>
> --
> "There are two kinds of people in this world: those who believe there
> are two kinds of people in this world and those who know better."
>
> --
> 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 jacoco+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jacoco/CAE6YT8SOkb-y9FdU8hX6fmGXtaztuy2MzFSZ%3Df7ri5PDpdyJWw%40mail.gmail.com
> [11].
> For more options, visit https://groups.google.com/d/optout.
>
>
> Links:
> ------
> [1] http://www.eclemma.org/jacoco/trunk/doc/report-aggregate-mojo.html
> [2] https://groups.google.com/d/optout
> [3] https://groups.google.com/d/topic/jacoco/Wo4OC1zvT9k/unsubscribe
> [4]
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com
> [5]
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [8]
> https://groups.google.com/d/msgid/jacoco/938d3232-ca3e-475c-990e-82e82f2ea503%40googlegroups.com?utm_medium=email&amp;amp;utm_source=footer
> [9]
> https://groups.google.com/d/msgid/jacoco/CAE6YT8QASCFDrc62O-g%3D9SwEUrgBhVnmJ%3DX1zDfkLM%3DS-T9fBw%40mail.gmail.com?utm_medium=email&amp;utm_source=footer
> [10]
> https://groups.google.com/d/msgid/jacoco/09433a19aef31bc6d6eaf8041ba5c150%40mountainminds.com
> [11]
> https://groups.google.com/d/msgid/jacoco/CAE6YT8SOkb-y9FdU8hX6fmGXtaztuy2MzFSZ%3Df7ri5PDpdyJWw%40mail.gmail.com?utm_medium=email&utm_source=footer
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages