I am trying to get the Code Analysis done with SonarCloud using the Github actions for my .NET Core application. I have added the below code in my build.yml file for .NET Core Build & Test to check if Code Coverage is populating in SonarCloud.io,
Which is generating .coverage file and the github run on windows-latest instance. But I am seeing 0.0% for the Coverage in the SonarCloud’s Project Summary.
Anything I am missing here to get the value for the CodeCoverage.
P.S The same thing happened in the Azure DevOps Pipeline implementation with SonarCloud extensions. Its showing 0.0% for the Coverage. Test & ScanEnd Logs.txt (21.0 KB) build.yml.txt (2.1 KB)
When using the dotnet tool the coverage file is not automatically converted to xml as it can do with the .NET Framework version of the scanner. Microsoft have recently released an alternative tool that can generate the xml in the correct format called the dotnet-coverage tool, in this scenario I would recommend you try this.