A joint post by Llewellyn Falco and Michael Kennedy
[Update: Get the videos and additional downloads for this webcast.]
As a follow-up to our “Avoiding 5 Common Pitfalls in Unit Testing” article we did a webcast where we took a problem from the audience and solved it live and unrehearsed on stage. These kinds of performances are always a risk but that’s part of what makes them fun.
Of course, the question is could we have done it better? Here’s your chance to try it for yourself (details below).
Our viewers chose to have us build the game Space Invaders. The first thing we had to do to sketch out a basic scenario we could implement. We started with a picture to remind what Space Invaders even was:
This was too big of a scenario for us to tackle in the allotted 40 minutes for programming. So then we started by creating a simpler scenario which we sketched out on the “whiteboard”:
[Update: See the follow-up post here: TDD Invades Space Invaders]
Tuesday, October 27, 2009 at 10am Pacific time Llewellyn Falco and I will be giving a live, unscripted, and no safety-net demonstration of Test Driven Development (TDD) as part of the DevelopMentor webinar series (this particular series is a 3-part series on Agile development).
We already have a bunch of attendees registered. But we have room for as many of you who are interested in agile and TDD. Sign up here:
In addition to core TDD techniques, you will see how an amazing technique and set of tools designed by Llewellyn called Approval Tests makes writing tests as simple as verifying an image or text file. Tired of writing 50 lines of test code for every 50 lines of production code but you still want the power of TDD? You need to learn more about Approvals and we’ll demo that live tomorrow!
I hope to see you all online. Feel free to help me get the word out by tweeting this or shouting it (see icons below).
This post describes a unit testing library for testing Windows Workflow Foundations.It is not a framework like HarnessIt, NUnit, or MsTest. Rather it’s a library that can be used in conjunction with any of these testing frameworks.
Download the library with sample test project here:
Kennedy.WorkflowTesting.zip (216 KB)
You can also just jump to the code.
First a Little History:
Last September I posted this teaser entitled Unit Testing Coming to a Workflow Near You. My intention was to post this article that you’re reading now shortly thereafter when I got some free time to polish things up. In that previous post, I highlighted what I could determine to be the current state-of-the-art with regard to unit testing workflows, circa September 2008.
I’ll be speaking tonight at The Central New Jersey .NET User Group (http://www.njdotnet.net) on one of my favorite topics: Five Fundamental Object Oriented Design Principles for Agile Development.
Thanks to Jason Beres (http://www.geekswithblogs.net/jberes) for inviting me to speak at his user group and welcoming me to New Jersey.
Once you’ve attended the talk, you might be interested in downloading the slides and sample code:
You also might want to look into some of the tools I was using in Visual Studio. See an older post on my tricked out Visual Studio.
You often hear it stated by very bright people that they thought they understood object oriented design until they began practicing Test Driven Development (TDD). I definitely include myself in that group (the misunderstanding OOD part anyway!).
Here is a list of the very best books I have found that helps bridge the divide between OOD and Agile for those of you who are currently making that transition. They are highly recommended.
Agile Software Development, Principles, Patterns, and Practices
by Robert C. Martin
Refactoring: Improving the Design of Existing Code
by Martin Fowler
Working Effectively with Legacy Code
by Michael Feathers