How to exclude certain tests in the Visual Studio Test Runner?

前端 未结 7 1119
春和景丽
春和景丽 2020-12-09 01:45

I have attributes on certain tests that I ideally don\'t want to run on every build. Most of my tests are normal unit tests and I do want them to run on every build.

7条回答
  •  自闭症患者
    2020-12-09 02:33

    You can use the search filter in Unit Text Explorer.

    unit test explorer

    In the new Test Exlorer shipped with 2012, you can group tests by 'Test Results', 'FileName',... etc but in RTM build group/search by 'TestCategory' is not present from Test Explorer. However there is a filter in commandline and TeamBuild based on TestCategory (Running selective unit tests in VS 2012 RC using TestCaseFilter) in VS2012.

    From a member of VS dev Team, they understood the importance of this missing feature. It is in the backlog, and it should be available in furutre builds/updates.

    The following blog provides more details: http://blogs.msdn.com/b/vikramagrawal/archive/2012/07/23/running-selective-unit-tests-in-vs-2012-rc-using-testcasefilter.aspx

提交回复
热议问题