Is Clojure coverage supposed to show up?

56 views
Skip to first unread message

HalloweenEngineer

unread,
Sep 15, 2022, 6:50:58 PM9/15/22
to JaCoCo and EclEmma Users
When I import the jacoco.exec into IntelliJ, I see java coverage, but no Clojure coverage. Is that supposed to work or is Clojure not supported?

I've tried using the cli to generate an html report and am not seeing coverage of clj files there either, although it does at least show the clojure files. It just indicates they are 100% not covered.

Is it supposed to work? If it is, is there something I need to do with the javaagent config to make it work?

Marc Hoffmann

unread,
Sep 16, 2022, 1:18:50 AM9/16/22
to JaCoCo and EclEmma Users
Hi,

theoretically JaCoCo can be used with any class files. If there is is no coverage shown at all this looks like a general problem with the setup. Please see this FAQ entry;

Why does a class show as not covered although it has been executed?

First make sure execution data has been collected. For this select the Sessions link on the top right corner of the HTML report and check whether the class in question is listed. If it is listed but not linked the class at execution time is a different class file. Make sure you're using the exact same class file at runtime as for report generation. Note that some tools (e.g. EJB containers, mocking frameworks) might modify your class files at runtime. Please see the chapter about class ids for a detailed discussion. 

But there is no official support for Clojure. Unlike Java, Kotlin, Scala and Groovy we don’t have integration tests for it.

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/4f8c443b-0b21-4699-bee1-a749f1559833n%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages