Commit 371c1146 authored by xiao-hesheng's avatar xiao-hesheng
Browse files

优化脚本

parent 31f1d700
# -*- encoding=utf8 -*-
__author__ = "xiaohesheng"
"""
case_tag:api,mdm-web,医院注册时医院已存在,id2249,id2249-3,sit,on,10086
主数据平台:医院注册时医院已存在
"""
from common.common_func import commonFuc
module = "mdm3-hs"
# 注册企业
url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "insertHosRegistInfo_url")
# #获取请求头信息
headers = commonFuc().get_business_data(module, "json_headers",
commonFuc().get_business_data(module, "json_contentType"))
h_name = commonFuc().get_business_data(module, "name1") # 获取前缀name
h_name = h_name + commonFuc().randomString(5) # 随机数生成拼接企业名称
request_body = commonFuc().get_business_data(module, "payload",h_name,h_name,h_name,h_name,h_name,h_name,h_name,h_name)
# 发送请求
result = commonFuc().http_post(url, request_body, headers)
# 发送请求
result1 = commonFuc().http_post(url, request_body, headers)
#获取接口返回数据
check_dict = commonFuc().get_business_data(module, "checkDict1")
#断言实际结果中是否包含预期结果的内容
commonFuc().check_result(check_dict, result1)
......@@ -224,5 +224,4 @@ def p_m_a():
print('username',username)
return username,goodsName,module
# p_m_a()
FileUtils().w_info(p_m_a(),'产品新增')
loginusername1:
aaaa: aaaa
bbbbbb: bbbbbb
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