mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-14 20:08:23 +08:00
fix:add list2json for better display
This commit is contained in:
@@ -33,7 +33,7 @@ def get_req_resp_record(resp_obj: Response) -> ReqRespData:
|
||||
def log_print(req_or_resp, r_type):
|
||||
msg = f"\n================== {r_type} details ==================\n"
|
||||
for key, value in req_or_resp.dict().items():
|
||||
if isinstance(value, dict):
|
||||
if isinstance(value, dict) or isinstance(value, list):
|
||||
value = json.dumps(value, indent=4, ensure_ascii=False)
|
||||
|
||||
msg += "{:<8} : {}\n".format(key, value)
|
||||
|
||||
Reference in New Issue
Block a user