fix tests(to handle the error)