mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-08 17:09:33 +08:00
fix: log testcase duration before raise ValidationFailure
This commit is contained in:
@@ -12,6 +12,7 @@
|
|||||||
- fix: missing request json
|
- fix: missing request json
|
||||||
- fix: override testsuite/testcase config verify
|
- fix: override testsuite/testcase config verify
|
||||||
- fix: only strip whitespaces and tabs, \n\r are left because they maybe used in changeset
|
- fix: only strip whitespaces and tabs, \n\r are left because they maybe used in changeset
|
||||||
|
- fix: log testcase duration before raise ValidationFailure
|
||||||
|
|
||||||
**Changed**
|
**Changed**
|
||||||
|
|
||||||
|
|||||||
@@ -149,6 +149,8 @@ class HttpRunner(object):
|
|||||||
except ValidationFailure:
|
except ValidationFailure:
|
||||||
self.__session.data.success = False
|
self.__session.data.success = False
|
||||||
log_req_resp_details()
|
log_req_resp_details()
|
||||||
|
# log testcase duration before raise ValidationFailure
|
||||||
|
self.__duration = time.time() - self.__start_at
|
||||||
raise
|
raise
|
||||||
finally:
|
finally:
|
||||||
# save request & response meta data
|
# save request & response meta data
|
||||||
|
|||||||
Reference in New Issue
Block a user