A few months ago we had a problem where Eclipse could not automatically run all jUnit unit tests in a package if that package references a class called “enum”, which is a reserved word in Java 1.6. I’ll spare you the details, but we were forced to create a TestSuite. Normally we avoid this construction because it’s easy to create a new unit test and forget to add it to the correct TestSuit. So as a workaround we wrote some code which could build and return a TestSuite dynamically. Right-click in eclipse, select “Run as Unittest”, sit back and enjoy.
Lately this piece of code came in handy while testing another application, which required the removal of data from a database. Yes I know, Unittests should maybe not depend on databases because it leans towards integration testing, but here we are, and I need to solve it. I used the old TestSuite code and changed it so that the TestCase I needed to run first was singled out, while still maintaining the functionality of auto-detecting testcases in the source folder.




I’ve been struggling to get routes into my Garmin Zūmo® in such a way that it matches the plans of the original author, while at the same time setting the Garmin to “recalculate” so that when I take a wrong turn, it will send me back to the track. After reading a lot on the Garmin forums, and experimenting with this on my two recent road trips (one to Eifel and one to Sauerland in Germany) I can say I have found a way to do this. It’s a bit of work, but it will make your trip a lot more trouble-free. Here’s the recipe.
