I have been using NUnit since its early days but it has only been in the last six months that I have made the move to test driven development. TDD is concept of writing production code based on unit test cases that are written first. And using a framework such as NUnit enables the developer to write automated unit tests that will test the features of an application at a functional level thus encouraging test driven development.

TDD is a paradigm switch for many developers as it was for me. Sure I have been unit testing my code for years. I would employ techniques such as console applications, shell programs, and other types of test harnesses to test the functions of my code. But until recently I never
started the development of a module by writing unit tests first.

Test driven development is an investment up front in the quality of your code. That investment is in the form of the unit tests before production code. Many developers today write the production code first (after the design phase of course), followed by commenting the code, then followed by testing the code. And in many cases the later work of commenting and testing never happens because bug fixes become the developer's top priority. But by investing in the quality of the code at the start developers will find that bugs are reduced, the classes and functions of the code are better designed, and over all quality of the work is greatly improved. Best of all, refactoring code becomes less of a risk with TDD because recursion testing at the unit level is possible.

Here are some tip I would like to share that will hopefully help you make the move to test driven development:




posted by Kirby Turner | 08-Jun-2004 10:22 AM | comments (0)

Add Your Comment

Comment:
(No HTML)

Name:
E-mail/Web site:
Your e-mail/web site will not be published on this site. It is optional and will only be used by me should I need to contact you directly.
 
By checking this option, this site will remember your name and e-mail/web site on future visits. Uncheck this option to have the site not remember who you are on future visits.
 
Enter the code shown above:
Copyright © 1999-2008 Kirby Turner.
Site software written by White Peak Software Inc, a provider of custom software and software development coaching.