My testing code (often, not unit tests), is generally much bigger than the code under test, but I'm just an old fogey, and everyone knows that old dudes can't code. I’m pretty sure that my code is so bad, it needs all that testing.
I've learned that lots of folks have some "litmus test," that they like to apply to others, where, if not passed, they are "bad programmers." In my case, I've learned that I'm a really "bad programmer," because I fail everyone's litmus test. In fact, I make a point of it.
Hey, it's a big world, and there's lots of freedom to believe as we please.
I did write something about test harnesses vs. unit tests, a couple of years ago: https://littlegreenviper.com/miscellany/testing-harness-vs-u...
TL;DR, test like crazy, but test smart.
My testing code (often, not unit tests), is generally much bigger than the code under test, but I'm just an old fogey, and everyone knows that old dudes can't code. I’m pretty sure that my code is so bad, it needs all that testing.
I've learned that lots of folks have some "litmus test," that they like to apply to others, where, if not passed, they are "bad programmers." In my case, I've learned that I'm a really "bad programmer," because I fail everyone's litmus test. In fact, I make a point of it.
Hey, it's a big world, and there's lots of freedom to believe as we please.