
An unexpectedly popular feature of jMock has been its library of Constraints. A constraint is a very simple object: it returns a boolean indicating if it matches another object and can describe itself. People have found this very useful. As well as extending JUnit's assert method, jMock constraints have been used for validating user input, filtering streams and collections and describing validity rules for incoming messages. However, people have felt uncomfortable using them in production code because they are part of a testing library.
Well, they need worry no more. Joe Walnes has pulled the constraints out of jMock into their own library called Hamcrest. Along the way he has renamed them to Matchers — "Hamcrest" is an anagram of "matchers" — and made them work with Java 5's generic type madness.
Hamcrest is split into two layers. A small, stable core API that defines the Matcher interface and abstract base class itself and a large library of matcher implementations. The intention is that the code API will change slowly to provide a stable base for other projects but the library will grow quickly as users contribute new matchers. Users will be able to drop new library releases into their codebase to extend the matchers available without breaking any libraries that are themselves dependent on Hamcrest's core.
The release of Hamcrest 1.0 should enable better integration between projects that provide or need matching. For example jMock 2 will use Hamcrest matchers instead of its own constraints and the Get In Line text pattern matcher is also a Hamcrest matcher. This means that jMock 2 users will be able use the Get In Line embedded domain-specific language to define text patterns in their expectations.

Chris Rimmer (on the right in the picture) presented an excellent comic-book style poster at XP Day to publicise the Oxtremists study group in Oxford.
That got me thinking... would a comic book be a good form for end-user documentation? It would be fun to write, would be good for showing graphical user interfaces and comic books have well known conventions for annotating pictures with to show movement and sound and direct the readers attention to detail.
I'm not the only one to think this. The developers of BJS, an open source game project, had the same idea and have already published their user manual as a comic book.
Update:These graphic resources could be useful for writing comic-book documentation.
Update:Kevin Cheng has posted a list of resources for creating comic book content for design and end-user documentation.
Ivan and I ran our Scrapheap Challenge workshop at the PoMoPro conference at the end of November.
The results were quite similar to our previous experience at OOPSLA in 2004: shell pipelines and dynamic languages that can easily run other programs won the day. Unlike last time, a few pairs had some success with Java. However no winning solution used Java and no all-Java solution was completed within the time frame.
As Ivan noted, the process that pairs followed had as much if not more of an effect as the technology they used. Unlike last time, not all pairs actually did pair programming. Some split the solution into parts and worked independently on separate modules and then brought them together for integration. Pairs that did pair programming did noticeably better than those that split the work into individual tasks. From what I observed, I don't think that pair programming itself was the decisive factor. Pairs that split the work were hit by integration problems at the end of the challenge that were too great to solve by the deadline. Pairs that pair-programmed grew the software incrementally and always had a running program. The only pair that did well when working independently integrated every 15 minutes or so instead of once at the end.
A valid criticism of the workshop was that our challenges were could easily be met by batch programs and involved a lot of text processing, so they were biased towards solutions using Unix-style pipes and filters. Next time we run the workshop we'll throw in some challenges to build interactive desktop applications so that Unix pipelines don't have such a strong advantage. If you're going to be at SPA 2007 on the Sunday, brush up on your GUI skills and show those Unix developers what real programming is all about. I hope some Smalltalk, LISP or J developers will turn up and demonstrate the obvious superiority of those development environments (instead of just talking about it).
Inspired by fairlygoodpractices.com, informativeworkspace.org and various conversations at XTC I create a poster about Fairly Good Practices for XP Day. The poster showed a some good practices from teams I've worked with or talked to.
I left space on the poster board for other delegates to pin their own ideas. Here's what had been pinned by the end of the conference:
Chris Cottee responded by creating his own ad-hoc poster about Staggeringly Bad Practices seen on real projects. Sadly his poster attracted more contributions than mine even though it started out as one hand-written index card. Here's what was on his board by the end of the conference:
There's no point in putting code into source control until we know it works in production.
Every time you have a "bad" day drop a practise and get everyone to reestimate everything until people begin rocking back and forth under tables.
We lost the source code and decompiled from production.
Thanks to everyone who contributed... whoever you are.