added a java unit test