SonarCloud: "uncovered code" despite tests not being set

We currently do not have sonar.tests set, which means that all code coverage is 0.
However all files are 90% red highlighted lines stating:
“Uncovered code”

This makes the UI useless, since you don’t see the forest for the trees - the uncovered errors are irrelevant to us.
Is there any way to change this, as sonarcloud is unusable for us like this.

Hey there.

sonar.tests won’t impact the calculation of coverage (except for excluding test files from the coverage calculation). Eventually you’ll want to raed about test coverage and SonarCloud and the correct analysis parameters to get coverage imported.

If you’re not ready to look at coverage at all right now, you can adjust your analysis scope to exclude all files from code coverage calculation (sonar.coverage.exclusions=**/*)

Thank you!

1 Like