Monday, February 18, 2013

Almost But Not Quite Done

Today I spent most of my time cleaning up my Tic-Tac-Toe code and adding tests in a few areas that were lacking. I was feeling pretty confident until I said I was done. Then I hadn't added a Gemfile. Then it was missing version numbers and I needed a .rvmrc file as well. Oh, and hey, the Qt version keeps not letting the player make a move. To explain how this happened, let me say that the Qt version doesn't lend itself to testing (at least not in a way that I know of). This illustrates what a dangerous world it is without tests to back up assertions.

In the end, I finished everything except the Qt issue. That has to do with wanting to lock the board when it's not a human player's turn and then unlocking it when it is. The real problem I have with this is that I'm not even sure if it's necessary, but I have no way to accurately test it. So tomorrow, I'm going to remove the locking and see if anyone can break my game. If not, then the locking is probably not necessary.

No comments:

Post a Comment