Execute only one unit test while debugging in Visual Studio 2008

后端 未结 6 989
梦毁少年i
梦毁少年i 2020-12-29 21:09

Is there a way to select which TestMethods you want to execute in Visual Studio 2008 Unit Test project while debugging? I want to debug one particular test without having m

6条回答
  •  孤城傲影
    2020-12-29 21:30

    If you want to debug while running your tests under an ASP.NET solution, check out the MSDN article "How to: Debug while Running a Test in an ASP.NET Solution" at http://msdn.microsoft.com/en-us/library/ms243172.aspx.

    I had to do this tonight and partially followed the instructions for "Debugging While Running on ASP.NET Development Server", setting in web.config and the System.Diagnostics.Debugger.Break() statement at the start of the method. However, I executed with the "Debug Checked Tests" command (Ctrl+R, Ctrl+T) which produced a Just-in-time debugger prompts and ran up a new instance of Visual Studio (I'm using VS2010 Beta2). It worked well.

提交回复
热议问题