Just tested SonarScanner 5.3.1 (global tool) with .NET 5 Razor Component Library and Blazor Projects. Unfortunately I still can’t see any Lines of Code or Issues in .cs files.
Welcome to the community! I moved your reply to a new topic (as per instructions in FAQ - SonarSource Community)
Could you please share your debug logs with us - for all three steps of the analysis (Begin, build and End)?
- SonarScanner.MSBuild.exe begin /k:“MyProject” /d:sonar.verbose=true
- msbuild /v:d
it had nothing to do with the type of my projects. My projects were recognized as test-projects. That was the problem.
I found this line in my logs:
INFO: Found 4 MSBuild C# projects: 1 MAIN project. 3 TEST projects.
I added this to my *.csproj files:
<PropertyGroup> <SonarQubeTestProject>false</SonarQubeTestProject> </PropertyGroup>
Now it works.
Found the solution here:
Problem with C# project analysis - Get help / SonarCloud - SonarSource Community
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.