2016-02-08 53 views
1

我們使用VSTS構建標準SonarQube構建步驟:失敗VSTS建設如果SonarQube失敗質量門

  • SonarQube爲的MSBuild - 開始分析
  • ...建立
  • SonarQube爲的MSBuild - 結束分析

生成後的一段時間我可以看到SonarQube中的分析結果 - 是否通過編輯或失敗的質量門。 但是,即使質量門失敗,VSTS構建也會成功。

如果quaility gate失敗,有沒有辦法使VSTS的構建失敗?

在此之後: http://docs.sonarqube.org/display/SONAR/Breaking+the+CI+Build 我試圖尋找報告,task.txt文件,但我無法看到它的任何地方。

我可能只需要運行MSBuild.SonarQube.Runner.exe作爲命令行構建步驟,如下所述: http://docs.sonarqube.org/display/SONAR/Analyzing+with+SonarQube+Scanner+for+MSBuild#AnalyzingwithSonarQubeScannerforMSBuild-AnalyzingfromtheCommandLine

但我想我應該先嚐試標準打造步驟爲SonarQube

回答