Multi module project coverage

java
tests
maven
coverage
sonarqube

(Sergio Pérez Felipe) #1

I have two projects, first one is a Java project, consisting of microservices endpoints (REST), and the second one is a project that launches requests to the endpoints from the first project (this project has only test classes).
I can check coverage from each project independently, but I want to check coverage from the endpoints project, using the TEST project (which throws requests to the endpoints).

How can I do it?
Both projects are visible from SonarQube (I’m using SonarQube 6 + Jacoco 0.8.0 + SpringBoot 2.0.5 + JUnit + Maven).


(Lorenzo Bettini) #2

You need to use Jacoco capabilities to do a “report aggregate”.
You might take some hints from my blog post http://www.lorenzobettini.it/2018/01/analyzing-eclipse-plug-in-projects-with-sonarqube/

hope this helps