Run an NUnit test without using the mouse?
Asked Answered
R

3

7

When I want to run 1 test, I always have to right-click the method declaration and click "Run Test". Is there a way to do this without using the mouse?

Respiration answered 13/10, 2009 at 15:22 Comment(1)
What test runner you are using?Calamondin
T
-1

A quick google for "TestDriven.NET keyboard shortcuts" gives a few helpful pages.

http://weblogs.asp.net/nunitaddin/archive/2004/08/30/222447.aspx

http://www.lostechies.com/blogs/jimmy_bogard/archive/2008/02/27/testdriven-net-keyboard-shortcut.aspx

Tobi answered 13/10, 2009 at 15:56 Comment(0)
L
2

See if there are any relevant entries from TestDriven.NET in Tools - Options - Keyboard (for instance, ReSharper adds "ReSharper.ReSharper_UnitTest_ContextRun", which allows to run a unit test method editor cursor is currently in) and bind that to some keyboard shortcut.

Lassitude answered 13/10, 2009 at 15:41 Comment(1)
Thanks - I was googling to try and remember the R# command that does that. It really REALLY should be a default IMOMythify
P
0

If you go to Tool=> Options => Keyboard then you can create a new shortcut key to run the unit test for a method or the complete suite. Just pick up the command from the list and assign a key.

Proclamation answered 13/10, 2009 at 15:42 Comment(0)
T
-1

A quick google for "TestDriven.NET keyboard shortcuts" gives a few helpful pages.

http://weblogs.asp.net/nunitaddin/archive/2004/08/30/222447.aspx

http://www.lostechies.com/blogs/jimmy_bogard/archive/2008/02/27/testdriven-net-keyboard-shortcut.aspx

Tobi answered 13/10, 2009 at 15:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.