TDD - It's not just for testing
I have to rework a huge piece of my site (MtgDiscover.com) for collecting magic cards. Specifically, the cosmos document for my collection got to big. So I need to switch to Azure SQL.
I have 4 queries that run against my collection document. They are very basic. Any additional processing is done in code.
I am asking myself; What do these very similar queries return... what maths are applied? What's the final output?
Ya know what'd tell me - Tests. If I had tests I'd have the answer of how the system behaves.
I've said it before; Testing is FSCKING CRITICAL to the maintainability of a system. I've also said that I'm lazy. And want this fucker done.
Through it all; I am enjoying all of the little "damn it, tests would help" that I'm encountering.
There are parts where I think tests would have slowed me down; because 90% of this project has been prototyped into production... Not a healthy environment for tests or TDD.
While I'm suffering, and doing the exact opposite of what I should be, I am getting a GREAT refresher of all the little things tests bring to a code base... by not having them... I'm sad.