Commit 0a1c3826 authored by liguangyu06's avatar liguangyu06
Browse files

优化

parent 90828884
No related merge requests found
Showing with 4 additions and 2 deletions
+4 -2
......@@ -36,8 +36,10 @@ request_body = commonFuc().get_business_data(module, "payload33")
result = requests.post(url, json=request_body, headers=headers)
# 获取接口响应时间
api_time = float(result.elapsed.total_seconds())
result = json.loads(result.content)
# 将接口响应时间添加至result
result = json.loads(result.content)
result["api_time"] = api_time
# print(result)
# 获取预期结果
check_dict = commonFuc().get_business_data(module, "checkDict33")
......@@ -55,7 +57,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db")
# 数据库查询返利发放规则状态
sql = "SELECT t.rebateTripId FROM `cmdc-order`.tc_rebatetrip t"
result = {"total": len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql))}
result["api_time"] = api_time
# print(result)
# 获取预期结果
check_dict = commonFuc().get_business_data(module, "checkDict33_1", total)
......
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