0 tests but Quality Gate passes anyways

Hi there, I guess I don’t really understand how exactly the Quality Gate works. I work in a scientific environment, so lots of python code, but 0 testing. We’re trying to improve this, however the Quality Gate always passes when the coverage is 0%. Is there a setting to control this?

Hey there.

Can you share some additional information, like how your Quality Gate is configured, screenshots where you see an inconsistency between the metrics reported and the status of the Quality Gate… the more information, the more likely somebody can assist!

Hello and thank you for the replay. I am using the default “Sonar way lenient” in Developer Edition v10.8.1 for all our projects.
“New Code” is set to the default (“Previous Version”). Our code changes sporadically.
Here is an example of what I am talking about:

Our goal would be to ding projects that have less than the 50% coverage threshold set by the quality gate, not just in new code, but overall. It’s not clear how this can be configured, if at all.
Thanx!

Sonar Way Lenient isn’t built-in to SonarQube, It must be something specific on your instance.

It’s also worth noting that with a few exceptions (accepting an issue or marking it as false-positive), Quality Gates won’t recompute until there’s a new analysis. All these projects haven’t been analyzed in 6+ months, so if you’ve changed the Quality Gate in the meantime… a new scan is in order.