WIP: Fixed most of the test cases