Commit a0887366 authored by liguangyu06's avatar liguangyu06
Browse files

增加响应时间获取

parent 004ccbc3
......@@ -31,6 +31,8 @@ request_body = commonFuc().get_business_data(module, "payload")
"""
# 发送请求
result = requests.post(url, json=request_body, headers=headers)
# 获取接口响应时间
api_time = result.elapsed.total_seconds()
result = json.loads(result.content)
# print(result)
if result["success"]:
......
......@@ -32,6 +32,8 @@ request_body = commonFuc().get_business_data(module, "payload2")
"""
# 发送请求
result = requests.post(url, json=request_body, headers=headers)
# 获取接口响应时间
api_time = result.elapsed.total_seconds()
result = json.loads(result.content)
# print(result)
# 获取预期结果
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment