Adding Java tests