【问题标题】:When running Stylecop in Sonar, how do I make it analyze projects identified as test projects?在 Sonar 中运行 Stylecop 时,如何让它分析识别为测试项目的项目?
【发布时间】:2012-11-04 01:24:40
【问题描述】:

好的,假设我想按照规则生活,像对待生产代码一样谨慎对待您的测试代码。如何让 Sonar 和 Stylecop 分析我的测试项目?

我基本上已经在我的 sonar-project.properties 文件中写了这个:

#Core C# Settings 
sonar.dotnet.visualstudio.solution.file=SomeSolution.sln 
sonar.dotnet.excludeGeneratedCode=true
sonar.dotnet.version=4.0
sonar.donet.visualstudio.testProjectPattern=*.Tests

#StyleCop
sonar.stylecop.mode=

阅读声纳构建日志,我看到除了测试(即 SomeTestProject.Tests)项目之外的所有项目都由 Stylecop 分析。

如何让 sonar+stylecop 也分析我的 Tests 项目?

【问题讨论】:

    标签: c# testing sonarqube stylecop


    【解决方案1】:

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-07-31
      • 2018-09-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多