Saturday, February 6, 2010

Followup on mocking frameworks for Java

So, a week has passed and my mocking framework is fairly complete for a first release. All the information can be found on I expect some slight API changes in the near future, adding a few more (but not many) features and fixing some bugs (though I have no known at this time).

I'd like to think that my experiment was a success, but how can I know how good it really is unless I get real users for it. It's a tricky situation. I personally think it has a better overall design than Mockito and mostly the same featureset, but generally you need to be significantly better for users to switch. I can't say I'm any different myself, why would I replace a library I use for a slightly better, if it would cost me time and effort to do so?

So there are a couple of issues I need to work on before I can have an actual userbase:

  1. Make it better than Mockito. This is by itself hard, since Mockito is already a very good mocking framework. Of all the mocking frameworks I've seen, it's by far superior. So I need to have all the features that Mockito has, plus a lot more.
  2. Figure out any realistic test usecases where Mockachino is better than Mockito. Given my knowledge of my own design and the design of Mockito, this should be doable to some extent at least.
  3. Make converting from Mockito to Mockachino easy. If you have a large codebase you don't want to manually rewrite all your tests to change framework. Maybe it is possible to write a small application that can convert existing java tests to use Mockachino instead of other frameworks (EasyMock, Mockito).
  4. Let people know it exists. This is hard. Word of mouth only goes so far. Some loose ideas include trying to make google rank the project site higher for relevant search terms, such as mocking and java. Also, I could inform tech bloggers that it exists so it can mentioned in articles that compare mocking frameworks.

Of course, the technical challenge is by itself worth something, and I definitely feel I have learned from it.

I guess I can sum up this entire entry in a single sentence.
If a code project falls in the internet forest and no one hears it, does it make a sound?

1 comment:

Olle said...

Seems like you put some work and thought into this. Good luck and I'm keeping an eye on the process!

Post a Comment