added some junit test cases