Hi,
A solution I’m analysing in SonarCloud via Azure Yaml Pipelines is showing code smells in the test projects. I would like to prevent code smells in test projects being analyzed but I can’t seem to prevent it.
I tried sonar.exclusions AND sonar.test.exclusions in yaml pipeline.
The task used is:
- task: SonarQubePrepare@6
inputs:
SonarQube: 'taxprepwebsonarqube'
scannerMode: 'MSBuild'
projectKey: '{projectKey}'
projectName: '{projectKey}'
projectVersion: '$(Build.BuildNumber)'
extraProperties: |
sonar.verbose=true
sonar.exclusions=**/Startup.cs,**/Program.cs
sonar.test.exclusions=**/<customfolder>/Tests/**
sonar.cs.vstest.reportsPaths=$(Agent.TempDirectory)\**\*.trx
Thanks