Hacker News new | ask | show | jobs
by icedchai 4848 days ago
TDD is often a waste of time. I worked at some place that had taken the TDD philosophy to the extreme: every getter and setter had a test.

On the opposite side of the spectrum, I worked on software that processed millions of dollars in daily transactions and there were maybe 5 "tests" in the whole system. This was about 500,000 lines of C and C++ code in the early 2000's.

My personal philosophy is to write unit tests where I think it's important, not test everything.

1 comments

I won't write tests for getters and setters, but then again, I try not to write getters and setters very much in the first place.