Unit Testing won’t save you testing time

Everybody knows the more you test the better quality of product will be. Unit testing (and other forms of automated testing) is a great helper here since you can literally run it on every change. And it’s cheap as well, people hour cost a lot more than machine hour. But will it guarantee quality of a product?

The answer is ‘maybe’. It depends on how you develop your software, how many testers you have, how your develop cycle is organized and other stuff. Don’t get me wrong, it will increase quality of a product anyway. On the other hand there’s a chance you won’t notice it but at the same time will be spending a lot of priceless development time on that. How can that be, how can such a nice and helpful technology cost you a lot of money and don’t give any value in return.

But there is an answer and it is - you have to understand what it could you help with and what it can’t possible manage. You have to understand that unit testing would test only regression of your code. You have to understand that it will test only specification and only things developer could think of while writing it. It is really, really small amount of the whole work amount on testing that should be done.

Yes, it will help you during refactoring one part of the system. No, you still have to test everything by hands since it won’t find errors it wasn’t developed for such as white text on white background.

Yes, it will test that your component is working by the spec and no, it won’t help finding the wrong use of it (which might work now and won’t in production).

Yes, it will take some responsibilities from testers and no, you cannot fire them since look&feel couldn’t be automated.

Yes, you could run it all the time and no, it won’t save you any testing time before release.

Yes, it could find some of the bugs and no, it won’t find all of them no matter how good coverage is.

Yes, it will save you some money on developers time since they would find errors faster and wouldn’t need costly context switch later but no, it won’t save you a lot of it since developers have to write the tests.

So if you want to save money or time - find another way. If you want to have a little less stress at the end of development cycle or a little more quality of the product - you definitely should do it.

Leave a Reply