Six Different Ways To Execute Tests in Visual Studio 2008

I remember the 1st time I tried to kick-off a “unit test” from Visual Studio 2005. I had to defer to the Web, I couldn’t figure it out. A year later and through everyday use of VS 2005 and VS 2008 I’ve slowly discovered various ways to get those tests rolling. Here are 6 different ways to start a test in Visual Studio 2008:


“Test Tools” Toolbar


image




Context Menu


clip_image001



Keyboard Shortcuts

Ctrl+R, Ctrl+T: Execute tests in current context
Ctrl+R, Ctrl+C: Execute tests in current test class
Ctrl+R, Ctrl+N: Execute tests in current namespace
Ctrl+R, Ctrl+A: Execute all tests in solution
Ctrl+R, Ctrl+D: Execute the tests in the last test run
Ctrl+R, Ctrl+F: Execute the failed tests of the last test run


Test List Editor


image



Test Results Pane


image



“Test” Menu


image

Leave a Reply

Your email address will not be published. Required fields are marked *