adding test cases for bugs found in code review