Added Junit test cases

Added all the necessary test cases as indicated in the assignment.