Check out this Six Rules of Unit Testing by Charles :
- Write the test first
- Never write a test that succeeds the first time
- Start with the null case, or something that doesn't work
- Don't be afraid of doing something trivial to make the test work
- Loose coupling and testability go hand in hand
- Use mock objects
http://radio.weblogs.com/0100190/stories/2002/07/25/sixRules
OfUnitTesting.html