add unit test in java post