Chess TDD 43: Pawns Good to Go
This episode was a lot of fun because all of the cards just kind of fell into place and I got the pawn done (with the exception of en passant). I had thought finishing up the pawn was going to take a number of episodes, but then there was a flurry of win. I’ll take it!
What I accomplish in this clip:
- Finished up the implementation of black pawn movement.
- Pretty well set with acceptance tests for pawn.
Here are some lessons to take away:
- Be on the lookout in your code for overly complicated boolean conditions; always look to simplify.
- If you can avoid creating more levels of inheritance and that sort of indirection, you should. That sort of thing can be a helpful tool, but you pay a price in complexity.