fixing bug in test case