Bug Statement:
I am using sonar.jacoco.reportPaths
for reporting code coverage on SonarQube. But when I use the same with sonar.coverage.jacoco.xmlReportPaths
then, it is now showing code coverage on Sonarqube server. As the previous property is deprecated, I need to move on new one. But with that code coverage is not working.
Below are the plugins and version used to report the code coverage.
SonarQube version is Version 7.9.1
Android Sonar plugin is org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.7.1
Jococo android plugin is com.dicedmelon.gradle:jacoco-android:0.1.4
Jococo toolchain tool version is 0.8.3
Below are the property used
sonarqube { properties { // Root project information property 'sonar.projectKey', 'AppNameAndroid' property 'sonar.projectName', 'AppName-Android' // Some properties that will be inherited by the modules property 'sonar.sources', 'src/main/java/com/app_name/app' property 'sonar.sourceEncoding', 'UTF-8' property 'sonar.exclusions', '**/*.html,**/*.css,**/*.png,**/*.jpg,**/*.JPG,**/io/ionic*,**/io/ionic**,**/io/ionic**/*.java,**/org/*,**/org/**,**/org/**/*.java,**/cordova/*,**/cordova/**,**/cordova/**/*.java,**/android/*,**/android/**,**/android/**/*.java,**/apache/commons/**' property 'sonar.scm.provider', 'git' property 'sonar.java.source', '1.8' property 'sonar.tests', ["src/test/java"] property 'sonar.java.coveragePlugin', "jacoco" property 'sonar.coverage.exclusions', '**/*.html,**/*.css,**/*.png,**/*.jpg,**/*.JPG,**/io/ionic*,**/io/ionic**,**/io/ionic**/*.java,**/org/*,**/org/**,**/org/**/*.java,**/cordova/*,**/cordova/**,**/cordova/**/*.java,**/android/*,**/android/**,**/android/**/*.java,**/apache/commons/**' // Below property needs to be use very soon //property 'sonar.coverage.jacoco.xmlReportPaths', "build/reports/jococo/jococoTestDevReleaseUnitTestReport/jacocoTestDevReleaseUnitTestReport.xml" property 'sonar.jacoco.reportPaths', "${project.buildDir}/jacoco/testDevReleaseUnitTest.exec" property 'sonar.junit.reportsPath', "${project.buildDir}/test-results/testDevReleaseUnitTest" property 'sonar.java.binaries', "${project.buildDir}/intermediates/javac/devRelease/compileDevReleaseJavaWithJavac/classes/com/visualogyx" property 'sonar.projectVersion', getFlavorVersionCode() } }
#bug: jococo xml report
#bug: jococo code-coverage issue