- ALM used: GitHub
- CI system used: Azure DevOps
- Languages of the repository: Ruby
I have been spending days to get code coverage exclusions to work since it’s including my specs and database migrations.
First I added the following in my pipeline:
- task: SonarCloudPrepare@1
But in the log it showed:
INFO: Indexing files...
INFO: Project configuration:
INFO: Excluded sources: **/*.erb
INFO: Excluded sources for coverage: db/migrate/**/*,spec/**/*,app/assets/**/*
INFO: Load project repositories
INFO: Load project repositories (done) | time=1265ms
INFO: 3654 files indexed
INFO: 0 files ignored because of inclusion/exclusion patterns
INFO: 0 files ignored because of scm ignore settings
Also when I add these folders in Administration > General Settings > Analysis scope > Coverage exclusions, code coverage is still including my specs and migrations.
Help would be very much appreciated