Updated to add test cases