Previous month:
December 2008
Next month:
February 2009

January 2009

Agile 2009 Proposal: Continuous Testing Evolved

I just finished submitting the first draft of my Agile 2009 presentation proposal: Continuous Testing Evolved. A lot has changed since I presented on the same topic last year, and I felt there was a lot of value in exploring some of those changes. It's also still a very new practice, and there's a lot of people who are unfamiliar with it and would benefit from this talk.

The talk would also be a great opportunity to demonstrate the new Eclipse plugin for Infinitest that Ryan and I are working on. I'm expecting a great many improvments to become possible because of this plugin, not the least of which is a significantly easier (and more familiar) installation process. 

Anyway, go give the proposal a read. Feedback is much appreciated. 

Soviet vs American Coupling

If you've worked on projects of any reasonable size, you know that managing dependencies is an very important part of software maintenance. However, the terms used to describe coupling between packages, efferent and afferent coupling, sound so much alike that I can never remember which one is which. So, I don't use those names...I have my own naming convention.

Yakov Smirnoff was well known in the 1980's for jokes using the following template:

In America, you [verb] [noun]
In Soviet Russia, [noun] [verb] you!


I use this now popularized meme to differentiate between the two basic types of coupling, like so:

In America, you depend on other classes
In Soviet Russia, other classes depend on you!

So American Coupling equates to efferent coupling, while Soviet Coupling is the same as afferent coupling. When using these cold-war era terms to analyze a particular class or package, I never get confused about which sort of coupling is which. I just think of Yakov and all becomes clear.

Build Failure Hardware Geekout

So, I built an alarm to notify our team of build failures.


Here's a shot of the internals:


Overhead view


It has an audible alarm and strobe light, is controlled via USB and runs off 12v power. The control software uses the RSS feed from our build server to watch for failures, and sets off the alarm accordingly.

This was a really fun project, and I'm still hunting around for cool electronics to hook up to it (I still have 2 open relays!)

Better Than @Ignore

If you're using the @Ignore annotation to disable failing JUnit 4 tests, you might consider using a different technique. By adding the expects=AssertionError.class parameter to the @Test annotation, you can actually assert that the test fails as expected, instead of just ignoring it.

Why would you want to do this? First of all, a failing test will not necessarily continue to fail in the same way if it's disabled. If you've written a test to reproduce a bug, but in the course of fixing it you find yourself blocked, you'll have to disable the test (or delete it) in order to check in. But the test you wrote is reproduces a known bug! By asserting that the code is broken, rather than simply not checking, you ensure that your test remains valid while other changes are happening in the system. 

You also help prevent someone else from adding a new (duplicated) test if they try and fix the bug. If they do, your test will start to fail because the bug is fixed, and the other programmer will be immediately aware of the duplication.

Give it a try!