Today was a real break through. I was talking to two senior developers here at Gestalt this morning about how to test some code one of the teams in the Joplin, MO office is working on. I came up with this awesome idea that I threw out there to these two devs. I said, “We need to be able to automagically take some test data, pump it through our module, let it do its voodoo, and then compare the results with what we think we should see in the end. Oh yeah, and this should be able to run constantly, whenever someone makes changes to the code base, this kind of test should run.” They were speechless. I think it was because of my brilliance. I know, that’s not being very humble, but this is a HUGE break through I made today. I can’t blame the guys if they were in awe of a Scrum Master’s ability to revolutionize the world of software development in less than a minute of thought. I wonder if this is how Alexander Graham Bell’s colleagues felt when he invented the telephone?
This new way of testing software certainly demands a book. Imagine, being able to write tests in code that are run continuously as the code evolves. The confidence you’d have in the quality of your code would go way up. Ideally, you would write these types of tests before you write the code. BAM! Another magic moment just happened as I typed that last sentence. Write the tests before you code. WTTBYC is pretty catchy, no? I think I have the title for my first book right there: Write the tests before you code (WTTBYC). Imagine how writing tests first might help improve the design of your code. If you need to think about how you’re going to test the code it might force you to write things a bit cleaner.
I think the only thing I need to work on now is fighting off all the tech book publishers with a stick. I may need to get an agent. What a game changing day it has been!