Fix for MODCLUSTER-432

note that the test also works with java 1.7 on macosx for example.
Oops fixing now.