finish hw4 test cases