Code Coveragexml file not being created from a trx file just coverge file gets generated

We are using sonarcloud and I have tried every possible avenue to generate the coveragexml file but I failed. I can confirm the trx and coverge file are generated but the coveragexml file is not generating and I cannot see it anywhere. We use azure devops there is integration already between azure dev ops and sonarcloud.
here are my log files for both test command and sonarcloud:
sonarlog.txt (274.0 KB)
testcommandlog.txt (6.4 KB)

  • ALM used :Azure DevOps
  • CI system used :Azure DevOps,
  • Scanner command used when applicable (private details masked)
  • Languages of the repository : c#
    my prepare and collect coverage are as follows
 - task: SonarCloudPrepare@1
     SonarCloud: 'Sonarqube SAS'
     organization: 'grdc'
     scannerMode: 'MSBuild'
     projectKey: 'GrainsRDC_feedback_service'
     projectName: 'feedback_service'
     extraProperties: |
 - task: DotNetCoreCLI@2
     command: 'test'
     projects: '**/*.Test.csproj'
     arguments: '--collect "Code coverage"'
     workingDirectory: '$(Agent.TempDirectory)'

Also I have already tested removing the vscoveragexml.reportPaths and still it did not work. the covergaexml not showing up when test command is run am I missing some magical arguments?

So I found what was going on
I was on wrong vm image for that specific stage I was using ubuntu that is why I had so much issue. the first stage was windows that is why I missed it. also I removed the coveragexml report path as suggested in the guide

1 Like