update exception handling and test case