GitHub Actions

16 views
Skip to first unread message

Rodrigo Graciano

unread,
Aug 12, 2020, 12:14:58 AM8/12/20
to JaCoCo and EclEmma Users
Hello. Is there a way to use JaCoCo with GitHub Actions?
My idea is to use an action to generate the report and add it to the repository.
Thank you

Marc Hoffmann

unread,
Aug 14, 2020, 5:58:50 AM8/14/20
to jac...@googlegroups.com
Hi Rodrigo,

you typically integrate JaCoCo in your build. JaCoCo has integrations for Ant, Maven, Gradle and many more: https://www.jacoco.org/jacoco/trunk/doc/integrations.html

With GitHub Action you trigger the build (which already include JaCoCo).

A separate GitHub Action for code coverage only does not seem to make sense to me, as you also need to compile your code and run your unit tests to collect code coverage.

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/18f5df71-a99b-48ac-a91c-75aae972d2dfn%40googlegroups.com.

Rodrigo Graciano

unread,
Aug 14, 2020, 11:40:39 AM8/14/20
to JaCoCo and EclEmma Users
Hi Marc, thank you.
I agree that it may not be the best approach but I'm playing with GitHub Actions and trying to understand what I can take out of that.

I was able to make it work and now I'm looking at the best way to extract a badge to be used in the README.md. Is there any place besides the .html file that has the total coverage % information?

Marc Hoffmann

unread,
Aug 14, 2020, 11:49:40 AM8/14/20
to jac...@googlegroups.com
Yes, the XML report contains total coverage data at the root node.

On 14. Aug 2020, at 17:40, Rodrigo Graciano <rodrigol...@gmail.com> wrote:

Hi Marc, thank you.

Rodrigo Graciano

unread,
Aug 14, 2020, 12:27:18 PM8/14/20
to jac...@googlegroups.com
Thanks Marc

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/U9YkkFtRjvY/unsubscribe.
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/DF896EA2-0181-472C-9CDD-5864AB00BD23%40mountainminds.com.


--

Rodrigo Graciano
rodrigol...@gmail.com
Reply all
Reply to author
Forward
0 new messages