Scalatest result (not coverage) on sonar is incorrect

Continuing the discussion from Getting Gradle, Java, Scala, Sonar and Jacoco to live in harmony?:

gradle + scalatest + sonar + scoverage is almost all working, except the test result (result-results/*.xml) are not reported at in sonar. Anyone know why and how to fix it?
Thanks

cl

Hey Chris,

A couple of questions to follow up on your issue.

  1. Which Sonar plugin are you using? the sonar-runner plugin gradle ships or the official gradle plugin from Sonarqube (http://docs.sonarqube.org/display/SONAR/Analyzing+with+Gradle)?

  2. Do you manually configure the sonar.surefire.reportsPath or sonar.junit.reportsPath properties in your build?

  3. Do you have a small reproducible example for the issue you’re facing?

cheers,
rené

Rene,
I am using the official gradle plugin from Sonarqube (5.1.2). I do manually configure the sonar.surefire.reportsPath or sonar.junit.reportsPath properties in build.
I created on github a gradle project to demonstrate this. (explained in issue in the readme there)

Thanks
-Chris

Hey, I can reproduce this issue with your sample project but I can’t see anything wrong in your gradle setup. Your best bet is to raise this issue at sonarqube I guess at https://jira.sonarsource.com/browse/SONARGRADL/?selectedTab=com.atlassian.jira.jira-projects-plugin:issues-panel

cheers,
René