Im trying to publish the Jacoco code coverage results from Azure pipeline to the SonarQube Server but coverage is always 0%.
what have you tried so far to achieve this
Added a prepare analysis task on SonarQube
Added the sonar scanner plugin (sonar-maven-plugin v 3.6.0.1398) and jacoco-maven-plugin v0.8.4 in the pom.xml.
Done a clean build or package goal.
Added publish quality gate results task
Using the self hosted Agent.
I could see the Jacoco coverage reports generated in Azure devops. but the coverage report is not getting published in SonarQube. Its always shows as 0%.
Kindly help me to resolve this issue and let me know if any further information is required
Thanks Ann for the response.
Solution in the post you suggested says this “I got this working if I specify an explicit path in the build arguments in Azure DevOps”.
So, do i need to make changes in the maven clean build task’s Test results files field?
Basically, i wanted to understand, where i can set the build arguments?