Testing your code

This is a little off topic from my typical purely technical discussion.

I'm a huge advocate of automated code verification.  Unit testing is preferred but really any method is acceptable as long as it gets the job done of testing your code.  IMHO, testing is the most important part of a developers job. 

Besides the 3 or 4 projects I am doing as part of my job at Microsoft, I work on numerous side projects.  Most of these come in the form of tools, libraries or little fun gadgets.  These are written in a variety of languages; C#, VB, C++, Powershell Script, etc ... 

This is pretty common amongst many devs I know.  We love our job and code before, during and after work.  Some of the devs I know don't bother automating testing of any of their tools.  When asked they generally respond that it's not worth it. 

I disagree strongly for certain types of tools.  For tools and libraries I own that I expect long term usage on, I test methodically.  On any given day I may update a couple of the tools.  The only item that adds sanity to the situation is testing.  This allows me to respond quickly to customer requests for features, bug fixes, etc  and get quick verification that I haven't introduced a regression. 

Skip to main content