fix[TAB][TAB]Widget[TAB]widget[ENTER]
That's all it takes to pop the following code into a C# source file in VS.NET 2005:
using NUnit.Framework;
[TestFixture]
public class TestWidget
{
Widget widget;
[SetUp]
public void Setup()
{
widget = new Widget();
}
[Test]
public void MyTest()
{
|
}
}
The pipe shows where your cursor ends up after you type that key sequence - you're ready to type your first test.
If you have Beta 2 of VS.NET you really should take a quick look at the snippet HOWTO and the snippet schema reference, so you can create these things yourself. They are trivial to build, and you'll save lots of time in the long run if you codify some of your more repetitive key sequences. The one thing that bums me out is that there are some features (like adding assembly references automatically) that are only supported in VB.NET - bah!
Posted
May 31 2005, 11:05 PM
by
keith-brown