I heard TDD very early, I know that there is a NUnit under the .NET until today, I really use it to write the program.
When I started writing, I had to write test while writing the program, and a lot of time energy was wasted. Adhere to the writing, the code has a certain size, slowly understand the role of unit testing. Give new features, or repair bugs, new features can be used after finishing. Test with NUnit, the test of new features is passed, but several original tests are bright red. Using unit tests can promptly discover new bugs to ensure that the original function is operating normally. It is not necessary to handle one by one. This is very precious.
Tips: Because NUNIT is not integrated with VS.NET, it is very troublesome to debug after the code is wrong. There is a variety of ways, in the project properties debug, change the debug mode in the start operation to the program so that we can set the launch application entry to the main program (C: / Program files / NUnit v2.1) BIN / NUNIT-GUI.EXE) This will start NUINT when running the program, and we can use breakpoints in our code to debug.
I feel that test drive development is really productive, just NUNIT and VS.NET integration is not very good, and the unit test in VS 2005 is warmly expected.