writing test cases