Unit Testing Checklist

 < Day Day Up > 

If you don’t test your code, you can never know for sure that it’s working. Beyond just catching bugs, a thorough suite of unit tests can give you the confidence you need to fine-tune your code. Think about these points when evaluating your own unit-testing practices:

  • Write unit tests for all code.

  • Write the tests as you go along. Don’t leave them for a “later” that may never come.

  • Make sure code passes unit tests and integration tests before you check it into the source code control system.

  • Use an automated tool such as NUnit to make the unit-testing process easy and repeatable.

  • Check the tests and any necessary setup files into your source code control system.

  • Consider using TDD to ensure 100% testing coverage.

  • Refactor code only when you have a thorough set of tests for the code.

Now that the code is starting to pile up, I want to turn our attention to the development environment itself. Visual Studio .NET is a fine IDE, but as you’ll see in the next chapter, many tools are available that can make it even better.

 < Day Day Up > 

Coder to Developer. Tools and Strategies for Delivering Your Software
Coder to Developer: Tools and Strategies for Delivering Your Software
ISBN: 078214327X
EAN: 2147483647
Year: 2003
Pages: 118

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net