Member-only story
When Developers Should Write Their Own Tests
My acquired taste is sure to provoke some criticism, but please hear me out to the end with an open mind, and with bias, ego and visceral reactions aside. If you still disagree after all is said, then crucify me to your heart’s content.
Many senior developers would already agree that unit testing is beneficial, but sometimes I do feel a bit of skepticism or pushback from others at the mention of using amazing code coverage tools (like NCrunch or VS Enterprise’s live unit testing) which hold developers accountable for every single line of code they write.
Maybe that is overkill for most of us, but have you considered how many conditional statements you write in a single year and try to map that to whether QA has a check for each case in their test suite? Have you even seen their test suite by the way? I don’t know about you, but I’d feel better with the absolute guarantee that at least something has executed through those alternate code pathways, especially when it’s automatically run in the background every time you change the code – as you’re typing.
Many people with a fair bit of passion for code quality will probably agree so far, but I am just getting started. I want to talk about user acceptance tests. Now, how many potential allies have I lost so far?
It’s Not My Job
A few years ago, when a fellow senior software developer heard this opinion of mine he looked at me sideways, almost as if insulted. He retorted that a…