add test case for fix issue 7976