mirror of
https://github.com/httprunner/httprunner.git
synced 2026-07-21 20:42:25 +08:00
group exceptions to 2 types: failure and error
This commit is contained in:
@@ -138,7 +138,7 @@ class TestResponse(ApiServerUnittest):
|
||||
]
|
||||
resp_obj = response.ResponseObject(resp)
|
||||
|
||||
with self.assertRaises(exception.ParseResponseError):
|
||||
with self.assertRaises(exception.ParseResponseFailure):
|
||||
resp_obj.extract_response(extract_binds_list)
|
||||
|
||||
extract_binds_list = [
|
||||
@@ -146,7 +146,7 @@ class TestResponse(ApiServerUnittest):
|
||||
]
|
||||
resp_obj = response.ResponseObject(resp)
|
||||
|
||||
with self.assertRaises(exception.ParseResponseError):
|
||||
with self.assertRaises(exception.ParseResponseFailure):
|
||||
resp_obj.extract_response(extract_binds_list)
|
||||
|
||||
def test_extract_response_json_string(self):
|
||||
@@ -225,5 +225,5 @@ class TestResponse(ApiServerUnittest):
|
||||
{"resp_content_body": "content.data.def"}
|
||||
]
|
||||
resp_obj = response.ResponseObject(resp)
|
||||
with self.assertRaises(exception.ParseResponseError):
|
||||
with self.assertRaises(exception.ParseResponseFailure):
|
||||
resp_obj.extract_response(extract_binds_list)
|
||||
|
||||
Reference in New Issue
Block a user