Sonarqube +黄瓜+ Gradle [英] Sonarqube + Cucumber + Gradle
问题描述
每当我尝试运行./gradlew sonarqube时,我都会收到以下消息:
Whenever I try to run ./gradlew sonarqube I get the following message:
Scenario: This is a test # sample/helloworld/readycheck.feature:3
Given This is my first step # StepDefinitions.This_is_my_first_step()
When This is my second step # StepDefinitions.This_is_my_second_step()
Then This is my third step # StepDefinitions.This_is_my_third_step()
1 Scenarios (1 passed)
3 Steps (3 passed)
0m0.221s
sample.helloworld.ReadyCheckTest > testDoGet STANDARD_OUT
Checking ready status...
Returing ready code: 200
sample.helloworld.ReadyCheckTest > testDoPost STANDARD_OUT
Set isReady to true
:buildDashboard UP-TO-DATE
:sonarqube
Resource not found: Scenario: This is a test
BUILD SUCCESSFUL
Total time: 11.112 secs
但是我没有黄瓜报告声纳。如何使其显示在仪表板上?
However, I do not have cucumber report on Sonar. How do I get it to show up on the dashboard?
推荐答案
SonarQube Java和Groovy插件仅支持遵循 surefire的测试报告格式(Maven)。
SonarQube Java and Groovy plugins only support test reports that follow "surefire" format (Maven).
如果黄瓜不是这种情况,则可以尝试将报告转换为Surefire(并继续依靠Java / Groovy插件导入)或通用XML格式,将由 SonarQube通用测试覆盖范围插件导入。
If this is not the case for cucumber you can try to convert your reports to either Surefire (and continue to rely on Java/Groovy plugins to import them) or to a generic XML format that will be imported by the SonarQube Generic Test Coverage plugin.
这篇关于Sonarqube +黄瓜+ Gradle的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!