Hi,
First of all IMO creation of new threads duplicating/related to your previous unanswered threads each two days
- two days ago - Target/jacoco.exec aggregated and target/site/jacoco/jacoco.xml are created but they are not posted into sonarqube
- five days ago - Trying to import aggregated jacoco file into sonar for code coverage
is not at all a good behavior in open community and is not a best way to get attention of its members.
Nevertheless given the provided information from these threads, I would advice you to read following answer:
which IMO explains pretty well how JaCoCoSensor
in Java SonarQube Plugin collects jacoco.exec
files specified by sonar.jacoco.reportPath
property and associates them with code in case of multi-module Maven projects.
And additionally to pay attention that JaCoCo XML Report Importer
refers to another sensor - to recently released GitHub - SonarSource/sonar-jacoco: SonarQube JaCoCo Plugin that instead of exec files reads XML file(s) specified by sonar.coverage.jacoco.xmlReportPaths
. But the rest of mechanics remain the same - SonarQube performs analysis of one module after another, during which one sensor reads XML
file(s) and another sensor reads exec
file(s) specified in corresponding property of corresponding module, and associates coverage data from these file(s) with source files in this module.
If all the above doesn’t help, and given that
while this works for others, I would highly advise you to reconsider approach and instead of questions provide complete example of project and its configuration to clearly demonstrate your difficulty. Because unlikely that someone can blindly correctly guess what is wrong based on the information that you provide so far. And here is example of how concrete complete examples are useful and helpful - No Coverage despite unit tests on an open source project - #2 by Godin
Regards,
Evgeny