Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
test
autotest-airtest-web-cmdc
Commits
cb6d8957
Commit
cb6d8957
authored
Oct 18, 2023
by
liguangyu06
Browse files
用例优化
parent
b6dd9c54
Changes
3
Hide whitespace changes
Inline
Side-by-side
air_case/cmdc_commodity_activity/赠品_jde0元_验证.air/赠品_jde0元_验证.py
View file @
cb6d8957
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
__author__
=
"liguangyu"
__author__
=
"liguangyu"
"""
"""
case_tag:cmdc_api,cmdc赠品(jde0元)活动验证,2262,2262-
3
0,sit,bs
case_tag:cmdc_api,cmdc赠品(jde0元)活动验证,2262,2262-
4
0,sit,bs
涉及接口:运营后台管理系统登录、活动基本信息获取、活动包含的商品信息和查询商品对应的促销活动等接口
涉及接口:运营后台管理系统登录、活动基本信息获取、活动包含的商品信息和查询商品对应的促销活动等接口
"""
"""
...
...
air_case/cmdc_coupon/优惠券_导入式_用户发放验证.air/优惠券_导入式_用户发放验证.py
View file @
cb6d8957
...
@@ -15,8 +15,8 @@ module = "cmdc_coupon"
...
@@ -15,8 +15,8 @@ module = "cmdc_coupon"
# 第一步登录多采商城获取cmdc_access_token
# 第一步登录多采商城获取cmdc_access_token
# 获取登录所需账号密码
# 获取登录所需账号密码
username
=
commonFuc
().
get_business_data
(
module
,
"username
3
"
)
username
=
commonFuc
().
get_business_data
(
module
,
"username
5
"
)
password
=
commonFuc
().
get_business_data
(
module
,
"password
3
"
)
password
=
commonFuc
().
get_business_data
(
module
,
"password
5
"
)
# 获取登录后Cmdc_access_token
# 获取登录后Cmdc_access_token
cmdc_access_token
=
CmdcMaiiLogin
(
username
,
password
).
get_token
()
cmdc_access_token
=
CmdcMaiiLogin
(
username
,
password
).
get_token
()
headers
=
commonFuc
().
get_business_data
(
module
,
"json_headers1"
,
cmdc_access_token
)
headers
=
commonFuc
().
get_business_data
(
module
,
"json_headers1"
,
cmdc_access_token
)
...
@@ -41,4 +41,4 @@ result = {"couponId": result["data"][0]["couponId"]}
...
@@ -41,4 +41,4 @@ result = {"couponId": result["data"][0]["couponId"]}
check_dict
=
commonFuc
().
get_business_data
(
module
,
"checkDict11"
)
check_dict
=
commonFuc
().
get_business_data
(
module
,
"checkDict11"
)
print
(
check_dict
)
print
(
check_dict
)
# 断言实际结果中是否包含预期结果的内容
# 断言实际结果中是否包含预期结果的内容
commonFuc
().
check_result
(
check_dict
,
result
)
commonFuc
().
check_result
(
check_dict
,
result
)
\ No newline at end of file
data/cmdc_coupon/data
View file @
cb6d8957
...
@@ -120,8 +120,8 @@ checkDict10: {"couponId": "%s"}
...
@@ -120,8 +120,8 @@ checkDict10: {"couponId": "%s"}
#我的优惠券列表
#我的优惠券列表
"url12": "/order/mall/myCoupon?status=101"
"url12": "/order/mall/myCoupon?status=101"
#活动客户信息-多采商城
#活动客户信息-多采商城
"username
3
": "BJ0500"
"username
5
": "BJ0500"
"password
3
": "Tss12345"
"password
5
": "Tss12345"
#预期结果
#预期结果
checkDict11: {"couponId": 10033}
checkDict11: {"couponId": 10033}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment