Comparing Infinitest and JUnitMax

 

As the author of Infinitest, a lot of people have been asking me what the difference is between my tool and JUnitMax. They both run tests continuously. They both are packaged as Eclipse plugins. They both report test errors in the "Problems" view just like compiler errors. In all honesty, their similarities are much more numerous than their differences. So it's hard for me to compare them in a way that's helpful to those that ask.

 

Compounding this is the fact that we're doing, on average, a couple of releases each week. I don't know if Kent is keeping track of what we're doing, but we're very aware of what he's doing. When it comes to responding to change, I think we do it as well as anyone. So any kind of feature by feature breakdown is likely to be out of date by the time anyone reads it.

 

There are some differences though, and I think they are significant. Here are three that I think are unlikely to change in the near term:


Continue reading "Comparing Infinitest and JUnitMax" »


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!

Hilarious.

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.


IMG_0033

Here's a shot of the internals:

IMG_0031

Overhead view

IMG_0030

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 useful...it 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!

The Dangers of Perfection

Is very difficult to improve upon perfection.

If you have the ideas in your head that your (product, tool, process, organization, whatever) is perfect, or even close to perfect, you're not going to have the right mindset to improve it.

Even if it was perfect at some point (highly unlikely), it's probably not now. A commitment to continuous improvement is the hallmark of a true craftsman. You have to accept the fact that everything you do is a hack; A workaround until you can find another way that's less hacky. That's not to imply that you shouldn't make it as good as you can get it...you should. You just need to realize that it can always be made better.