未在测试资源管理器中运行的测试 - Tests not running in Test Explorer

10/14 16:12
阅读数 0

问题:

I am currently working on a solution that has currently 32 Unittests.我目前正在研究一个目前有 32 个单元测试的解决方案。 I have been working with the resharper test runner - which works fine.我一直在使用 resharper 测试运行器 - 工作正常。 All tests are running, all tests are showing the right test outcome.所有测试都在运行,所有测试都显示正确的测试结果。

However, the tests are not running when using the Visual Studio test explorer.但是,使用 Visual Studio 测试资源管理器时未运行测试。

The Test Explorer is showing all unit tests, but once clicking on "Run All", all tests are getting greyed out and show no result of the test run:测试资源管理器显示所有单元测试,但是一旦单击“全部运行”,所有测试都会变灰并且不显示测试运行的结果:

在此处输入图片说明

  • All test classes are public所有测试类都是公开的
  • All test classes are having the [TestClass] attribute declared所有测试类都声明了[TestClass]属性
  • All test methods are using the [TestMethod] attribute所有测试方法都使用[TestMethod]属性
  • Both the productivity code and the test projects are targeting .NET 3.5.生产力代码和测试项目都针对 .NET 3.5。
  • I have already tried to clean build my solution, and / or delete all obj , bin , Debug and Release folders我已经尝试清理构建我的解决方案,和/或删除所有objbinDebugRelease文件夹

I'd appreciate any hints which would explain this behaviour.我很感激任何可以解释这种行为的提示。


解决方案:

参考一: https://en.stackoom.com/question/1a1nl
参考二: https://stackoom.com/question/1a1nl
展开阅读全文
打赏
0
0 收藏
分享
加载中
更多评论
打赏
0 评论
0 收藏
0
分享
返回顶部
顶部