I am using sbt-jacoco to calculate code coverage and would like to publish Jacoco test coverage results in Azure DevOps test reports.
Here are my tasks:
- script: "sbt jacoco"
displayName: Run Jacoco
- task: PublishCodeCoverageResults@1
displayName: Publish code coverage report
inputs:
codeCoverageTool: 'JaCoCo'
summaryFileLocation: $(System.DefaultWorkingDirectory)/target/scala-2.13/jacoco/report/html/index.html
reportDirectory: $(System.DefaultWorkingDirectory)/target/scala-2.13/jacoco/report
These tasks are executed successfully and the results are shared as an artifact on the pipeline. However, it also throws a warning which is
##[warning]No coverage data found. Check the build errors/warnings for more details.
I would like to see the results in a chart which is attached to the pipeline. Could you please help with this problem?