Test-driven design is probably more popular in the Ruby community than in other language communities. Nevertheless, test-driven design of graphical user interfaces is still seen as something of a black art. In this talk, I’ll demonstrate how to test-drive a Mac GUI, using either RubyCocoa or MacRuby. I’ll concentrate on opening a File Chooser, then move to drag-and-drop (if there’s time). Along the way, you’ll also see Shoulda, Assert{2.0}, and some hackery on top of FlexMock. Although the Mac’s GUI framework is probably friendlier to test-driven design than most, the principles should be broadly applicable.