Mike and Cami return, in this episode, to finish up the
Authorizer and then begin work on the
Sequencer. As they proceed through this, notice how diligent they are about refactoring the tests. They clearly understand that clean tests are essential for keeping the production code under control.
In the second tomato they have begun the logic of the
Sequencer. At first, everything goes quite well. They get the first few tests cases to pass without a problem. But then things start to go wrong, and they begin to flail.
They seem to recognize this, and so they do something quite astonishing. Rather then pressing on towards a brute force solution that seems wrong, they start cleaning up the tests. That is the mark of true professionals. When they are confused by a mess, their first reaction is to clean it. The tomato ends with a nice clean set of tests that fail.
Something happened during the break. Somebody got an insight! So as the third tomato begins, the flailing is over. They know what to do.
This is common in PDD (Pomodoro Driven Development). Many technical problems are solved during the five minutes or so away from the keyboard.
It all comes together easily, and the third tomato ends with nice clean code, clean tests, and a working