Sonar.coverage.exclusions in Jenkins pipeline


Same issue here in We use a SQ server in our Jenkins pipeline setup. Administration is done via the administration web interface.

When entering a pattern under Analysis Scope > Coverage Exclusion, the matching files are NOT excluded from code coverage (unexpected). In our case, coverage remains at about 46%.

When entering the EXACT same pattern under Analysis Scope > Global Source File Exclusions, the matching files are no longer analysed and are NOT taken in account for code coverage (expected). In our case, coverage increases to 95%.

Hope this helps.

1 Like

A post was merged into an existing topic: Sonar.Coverage.Exclusions not excluding as expected based on file regex pattern