Posts

Showing posts from September, 2023

Test-driven Development Is Not About Testing

 The fact that I'm flying to the Canary Islands for my winter holiday is not the point of the holiday. I don't love to fly, and would prefer to just sort of mysteriously "arrive" at my destination, ideally with a nice cold glass of Chardonnay in my hand. Unfortunately, there is the small matter of physical distance to be overcome. So I have to sit on a plane for four hours while about a thousand miles of fresh air whizzes by me. But I consider myself a holiday maker, not a passenger. The flight is not the point of the holiday. It is a means to an end. And someone who does test-driven development is not a tester. The tests are not the point. They are a means to an end. The end of TDD is well-designed, working code. In TDD, we use tests to specify what code we should write. The fact that we can run these executable specifications and get immediate feedback that our code works is a bonus, and a big one, but it is not the purpose of TDD. It is a very usef