小编ElG*_*ooo的帖子

Tests not running in Test Explorer

I am currently working on a solution that has currently 32 Unittests. I have been working with the resharper test runner - which works fine. All tests are running, all tests are showing the right test outcome. Now a coworker told me, that the tests are not running on his machine using the Visual Studio test explorer. They are not working either on my machine, so i can exclude some local missing files or something.

The Test Explorer is showing …

resharper unit-testing visual-studio visual-studio-2012

61
推荐指数
21
解决办法
4万
查看次数

禁用特定项目的代码分析规则

我们有一个包含多个项目的解决方案(一些生产代码项目,一些包含我们的单元测试的测试项目)。

基本上,我们希望对所有项目(包括测试项目)启用相同的代码分析规则,以使它们保持一致。尽管如此,我只是想为我们的测试项目禁用代码分析的两个规则(CA1707和CA1702)。我可以创建一个新的.ruleset文件,其中包含与我的主规则集相同的规则,但是我不想重复这些设置。假设,我们决定将来在主规则集中启用一个规则,我希望在我的testproject-ruleset中自动启用它。

这是定义我的主规则集,包含所有解决方案范围的通用规则(因此将不包括 CA 1707和CA 1702 )并为我的生产代码设置合并规则集的正确方法,使用主规则集作为基础,并另外包含其他规则集二?

还是有一种方法可以定义我的主规则集以包含所有规则,然后从规则集中显式排除它们?

code-analysis visual-studio visual-studio-2012

3
推荐指数
1
解决办法
2781
查看次数