使用伊斯坦布尔的sonarqube测试覆盖范围:无覆盖属性。跳过传感器

时间:2017-03-07 11:45:05

标签: javascript testing sonarqube test-coverage

我试图将伊斯坦布尔的一些测试覆盖率(lcov)报告输出到sonarqube,以使用Thoughtworks GO分析我们的测试覆盖率。有一个coverage / html文件夹正在输出,但sonarqube报告以下错误没有coverage属性。跳过传感器。这是我的属性文件,我缺少什么?

sonar.projectKey=transformers.allspark.ui
sonar.projectName=Transformers Allspark UI
sonar.projectVersion=1.0
sonar.host.url=https://sonarqube-security.test.ctmers.io
sonar.sources=.
sonar.projectBaseDir=.
sonar.language=js
sonar.sourceEncoding=UTF-8
sonar.javascript.lcov.reportPath=coverage/html

1 个答案:

答案 0 :(得分:1)

Thanks for responding. I've managed to fix this by replacing the last line with this : sonar.javascript.lcov.reportPath=coverage/html/lcov.info. It appears that sonarqube needs a path to a file (lcov.info) and not just the folder. Also my istanbul configuration was wrong because it needed to output lcov and not just a standard report.