We have java project repositories in bitbucket. For CI we are using Bitbucketpipeline.
For code scan, sonarcloud is used.
In bitbucket, there is a sonar scanner pipe, but the issue with using a pipe is, the code coverage we see in sonar console, is always 0%.
As a workaround we are using,
“gradle build jacocoTestReport sonarqube” command.
It is showing the coverage properly. However, now we want to enforce the quality gate in pipeline and fail the build if quality gate is failed.
The sonar quality gate pipe available in bitbucket requires a sonar scanner pipe. Hence, we cannot use the quality gate pipe.
Can someone tell us what command/api is to be used to enforce the quality gate in the bitbucket pipeline?
Thank you Benoit for your response.
So, if I understand correctly, as of now we cannot use sonar quality gate pipe with Bitbucket pipeline for Java repos as the sonar scanner pipe cannot be used for java.