Added Junit tests