2

We want to our Jacoco code coverage in some of our Java projects. Unfortunately, their maven and gradle configurations do not include generating Jacoco test reports.

There are 40+ Java projects and I don't have the time to fix all their pom.xml or gradle build files to add jacoco test coverage reports. What is the fastest way to scan them for code coverage? is there a way do to this without the need for modifying pom.xml or gradle build files.

I am using Eclipse IDE

  • If doing it manually takes too long or is too error prone, write a shell, batch or whatever script to automate it. – howlger Feb 04 '21 at 14:24

1 Answers1

1

Have you tried to add EclEmma (from Help Eclipse Marketplace and search for EclEmma)?

After the installation of EclEmma:

  • the context menu of a project also contains a Coverage As entry
  • And besides the debug button in the main toolbar will also be another button for running java code with code coverage analysis.
  • Once a program is run with code coverage a Coverage View will show up in the Eclipse IDE.

(PS recently released EclEmma 3.1.5 supports recently released Java 17 thanks to JaCoCo 0.8.7)

Nicola Landro
  • 336
  • 3
  • 17