Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
backend_auto
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
邓莹莹
backend_auto
Commits
0b0be6e5
Commit
0b0be6e5
authored
Jun 09, 2021
by
张伟男
Browse files
Options
Browse Files
Download
Plain Diff
merge
parents
f5c39050
74792e9c
Show whitespace changes
Inline
Side-by-side
Showing
31 changed files
with
609 additions
and
5 deletions
+609
-5
pay_request.py
all_backend_api/pay_request.py
+27
-0
pay_request.yaml
all_backend_api/pay_request.yaml
+11
-0
settlement_request.py
all_backend_api/settlement_request.py
+44
-0
settlement_request.yaml
all_backend_api/settlement_request.yaml
+56
-0
visual_beauty_card.py
all_backend_api/visual_beauty_card.py
+40
-0
visual_beauty_card.yaml
all_backend_api/visual_beauty_card.yaml
+47
-0
path_setting.py
path_setting.py
+24
-1
test_thirdPhone_login.py
test_backend_case/account_case/test_thirdPhone_login.py
+2
-1
__init__.py
test_backend_case/pay_case/__init__.py
+0
-0
test_wechat_prepay.py
test_backend_case/pay_case/test_wechat_prepay.py
+19
-0
__init__.py
test_backend_case/settlement_case/__init__.py
+0
-0
test_create_v1.py
test_backend_case/settlement_case/test_create_v1.py
+19
-0
test_pay.py
test_backend_case/settlement_case/test_pay.py
+19
-0
test_pay_v1.py
test_backend_case/settlement_case/test_pay_v1.py
+18
-0
test_preview_v1.py
test_backend_case/settlement_case/test_preview_v1.py
+18
-0
__init__.py
test_backend_case/visual_beauty_card_case/__init__.py
+0
-0
test_beautycard_filters.py
...d_case/visual_beauty_card_case/test_beautycard_filters.py
+22
-0
test_beautycard_skus.py
...kend_case/visual_beauty_card_case/test_beautycard_skus.py
+20
-0
test_visual_beauty_card_services.py
...sual_beauty_card_case/test_visual_beauty_card_services.py
+20
-0
login_thirdphone.yaml
test_backend_data/account_data/login_thirdphone.yaml
+6
-3
__init__.py
test_backend_data/pay_data/__init__.py
+0
-0
wechat_prepay.yaml
test_backend_data/pay_data/wechat_prepay.yaml
+4
-0
__init__.py
test_backend_data/settlement_data/__init__.py
+0
-0
create_v1.yaml
test_backend_data/settlement_data/create_v1.yaml
+12
-0
pay.yaml
test_backend_data/settlement_data/pay.yaml
+13
-0
pay_v1.yaml
test_backend_data/settlement_data/pay_v1.yaml
+8
-0
preview_v1.yaml
test_backend_data/settlement_data/preview_v1.yaml
+12
-0
__init__.py
test_backend_data/visual_beauty_card_data/__init__.py
+0
-0
beautycard_filters.yaml
...kend_data/visual_beauty_card_data/beautycard_filters.yaml
+17
-0
beautycard_skus.yaml
...backend_data/visual_beauty_card_data/beautycard_skus.yaml
+110
-0
visual_beauty_card_services.yaml
.../visual_beauty_card_data/visual_beauty_card_services.yaml
+21
-0
No files found.
all_backend_api/pay_request.py
0 → 100644
View file @
0b0be6e5
import
path_setting
from
in_common.base_request
import
BaseRequest
class
pay_request
(
BaseRequest
):
def
__init__
(
self
):
self
.
wechat_pay
=
self
.
api_load
(
path_setting
.
WECHAT_PAY
)
def
wechat_prepay
(
self
,
settlement_id
):
self
.
params
[
"settlement_id"
]
=
settlement_id
return
self
.
api_send
(
self
.
wechat_pay
[
"wechat_prepay"
])
def
alipay_prepay
(
self
,
settlement_id
,
version
,
is_huabei
,
huabei_period
):
self
.
params
[
"settlement_id"
]
=
settlement_id
self
.
params
[
"version"
]
=
version
self
.
params
[
"is_huabei"
]
=
is_huabei
self
.
params
[
"huabei_period"
]
=
huabei_period
return
self
.
api_send
(
self
.
preview
[
"pay_v1"
])
def
jump
(
self
,
ee
,
settlement_id
):
self
.
params
[
"settlement_id"
]
=
settlement_id
return
self
.
api_send
(
self
.
preview
[
"create_v1"
])
if
__name__
==
'__main__'
:
# print(settlement_request().preview_v1("beijing", "599428", 1, 1, 1, "true", 0))
print
(
pay_request
()
.
wechat_prepay
(
522139664651
))
\ No newline at end of file
all_backend_api/pay_request.yaml
0 → 100644
View file @
0b0be6e5
wechat_prepay
:
method
:
post
url
:
/pay/wechat/prepay
params
:
current_city_id
:
"
beijing"
version
:
7.44.0
data
:
settlement_id
:
${settlement_id}
isLogin
:
1
all_backend_api/settlement_request.py
0 → 100644
View file @
0b0be6e5
import
path_setting
from
in_common.base_request
import
BaseRequest
class
settlement_request
(
BaseRequest
):
def
__init__
(
self
):
self
.
preview
=
self
.
api_load
(
path_setting
.
PREVIEW_V1
)
def
preview_v1
(
self
,
current_city_id
,
service_item_id
,
number
,
use_platform_coupon
,
use_doctor_coupon
,
use_coupon_grey
,
is_create_groupbuy
):
self
.
params
[
"current_city_id"
]
=
current_city_id
self
.
params
[
"service_item_id"
]
=
service_item_id
self
.
params
[
"number"
]
=
number
self
.
params
[
"use_platform_coupon"
]
=
use_platform_coupon
self
.
params
[
"use_doctor_coupon"
]
=
use_doctor_coupon
self
.
params
[
"use_coupon_grey"
]
=
use_coupon_grey
self
.
params
[
"is_create_groupbuy"
]
=
is_create_groupbuy
return
self
.
api_send
(
self
.
preview
[
"preview_v1"
])
def
pay_v1
(
self
,
actual_pay
,
payment_final_price
,
is_contains_groupbuy_order
,
mul_orders_number
):
self
.
params
[
"actual_pay"
]
=
actual_pay
self
.
params
[
"payment_final_price"
]
=
payment_final_price
self
.
params
[
"is_contains_groupbuy_order"
]
=
is_contains_groupbuy_order
self
.
params
[
"mul_orders_number"
]
=
mul_orders_number
return
self
.
api_send
(
self
.
preview
[
"pay_v1"
])
def
create_v1
(
self
,
service_item_id
,
number
,
platform_coupon_id
,
use_point
,
is_doctor_see
,
doctor_coupon_id
,
insurance_info
,
is_create_groupbuy
):
self
.
params
[
"service_item_id"
]
=
service_item_id
self
.
params
[
"number"
]
=
number
self
.
params
[
"platform_coupon_id"
]
=
platform_coupon_id
self
.
params
[
"use_point"
]
=
use_point
self
.
params
[
"is_doctor_see"
]
=
is_doctor_see
self
.
params
[
"doctor_coupon_id"
]
=
doctor_coupon_id
self
.
params
[
"insurance_info"
]
=
insurance_info
self
.
params
[
"is_create_groupbuy"
]
=
is_create_groupbuy
return
self
.
api_send
(
self
.
preview
[
"create_v1"
])
def
pay
(
self
,
id
):
self
.
params
[
"id"
]
=
id
return
self
.
api_send
(
self
.
preview
[
"pay"
])
if
__name__
==
'__main__'
:
# print(settlement_request().preview_v1("beijing", "599428", 1, 1, 1, "true", 0))
print
(
settlement_request
()
.
create_v1
(
599428
,
1
,
""
,
0
,
1
,
""
,
[],
0
))
\ No newline at end of file
all_backend_api/settlement_request.yaml
0 → 100644
View file @
0b0be6e5
preview_v1
:
method
:
post
url
:
/api/settlement/preview/v1
params
:
current_city_id
:
${current_city_id}
data
:
service_item_id
:
${service_item_id}
number
:
${number}
use_platform_coupon
:
${use_platform_coupon}
use_doctor_coupon
:
${use_doctor_coupon}
use_coupon_grey
:
${use_coupon_grey}
is_create_groupbuy
:
${is_create_groupbuy}
json
:
{}
isLogin
:
1
#需要登录添加这个字段,值为1 0是不需要登录的情况,如不需要登录,可以不添加这个字段
pay_v1
:
method
:
get
url
:
/api/settlement/pay/v1
params
:
current_city_id
:
"
beijing"
actual_pay
:
${actual_pay}
payment_final_price
:
${payment_final_price}
is_contains_groupbuy_order
:
${is_contains_groupbuy_order}
mul_orders_number
:
${mul_orders_number}
data
:
{}
json
:
{}
isLogin
:
1
create_v1
:
method
:
post
url
:
/api/settlement/create/v1
params
:
current_city_id
:
"
beijing"
version
:
7.44.0
data
:
service_item_id
:
${service_item_id}
number
:
${number}
phone
:
"
18301089978"
platform_coupon_id
:
${platform_coupon_id}
use_point
:
${use_point}
is_doctor_see
:
${is_doctor_see}
doctor_coupon_id
:
${doctor_coupon_id}
insurance_info
:
${insurance_info}
is_create_groupbuy
:
${is_create_groupbuy}
isLogin
:
1
pay
:
method
:
get
url
:
/api/settlement/pay
params
:
current_city_id
:
"
beijing"
id
:
${id}
version
:
7.44.0
data
:
{}
isLogin
:
1
all_backend_api/visual_beauty_card.py
0 → 100644
View file @
0b0be6e5
import
path_setting
from
in_common.base_request
import
BaseRequest
class
visual_beauty_card_request
(
BaseRequest
):
def
__init__
(
self
):
#自定义专题-更美次卡橱窗组件商品
self
.
data
=
self
.
api_load
(
path_setting
.
VISUAL_BEAUTY_CARD_SERVICES_CONFIG
)
#自定义专题-更美次卡商品列表筛选器
self
.
data
=
self
.
api_load
(
path_setting
.
BEAUTYCARD_FILTERS_CONFIG
)
#自定义专题-更美次卡橱窗组件商品
def
visual_beauty_card_services
(
self
,
unit_id
,
current_city_id
,
page
,
page_size
,
version
,
device_id
=
'97B6764B-2135-4761-9911-701C38CBC272'
):
self
.
params
[
"unit_id"
]
=
unit_id
self
.
params
[
"current_city_id"
]
=
current_city_id
self
.
params
[
"page"
]
=
page
self
.
params
[
"page_size"
]
=
page_size
self
.
params
[
"version"
]
=
version
return
self
.
api_send
(
self
.
data
[
'visual_beauty_card_services'
])
#自定义专题-更美次卡商品列表筛选器
def
beautycard_filters
(
self
,
unit_id
,
current_city_id
,
version
,
device_id
=
'97B6764B-2135-4761-9911-701C38CBC272'
):
self
.
params
[
"unit_id"
]
=
unit_id
self
.
params
[
"current_city_id"
]
=
current_city_id
self
.
params
[
"version"
]
=
version
return
self
.
api_send
(
self
.
data
[
'beautycard_filters'
])
#自定义专题-更美次卡商品列表组件商品
def
beautycard_skus
(
self
,
unit_id
,
tag_id
,
area
,
sort_type
,
page
,
page_size
,
device_id
=
'97B6764B-2135-4761-9911-701C38CBC272'
):
self
.
params
[
"unit_id"
]
=
unit_id
self
.
params
[
"tag_id"
]
=
tag_id
self
.
params
[
"area"
]
=
area
self
.
params
[
"sort_type"
]
=
sort_type
self
.
params
[
"page"
]
=
page
self
.
params
[
"page_size"
]
=
page_size
return
self
.
api_send
(
self
.
data
[
'beautycard_skus'
])
\ No newline at end of file
all_backend_api/visual_beauty_card.yaml
0 → 100644
View file @
0b0be6e5
visual_beauty_card_services
:
method
:
GET
url
:
/api/janus/visual_beauty_card/services
params
:
#组件id
unit_id
:
${unit_id}
current_city_id
:
${current_city_id}
#分页
page
:
${page}
#分页大小
page_size
:
${page_size}
version
:
${version}
data
:
{}
json
:
{}
beautycard_filters
:
method
:
GET
url
:
/api/janus/visual_beauty_card/list_unit/filters
params
:
#组件id
unit_id
:
${unit_id}
current_city_id
:
${current_city_id}
version
:
${version}
data
:
{}
json
:
{}
beautycard_skus
:
method
:
GET
url
:
/api/janus/visual_beauty_card/list_unit/skus
params
:
#组件id
unit_id
:
${unit_id}
#类型筛选器(-1: 全部类型)
tag_id
:
${tag_id}
#城市筛选器
area
:
${area}
#排序方式(0: 默认排序, 1: 销量排序, 2: 价格排序, 3: 上架时间排序)
sort_type
:
${sort_type}
#分页
page
:
${page}
#分页大小
page_size
:
${page_size}
data
:
{}
json
:
{}
path_setting.py
View file @
0b0be6e5
...
@@ -225,7 +225,7 @@ POLYMER_CONFIG = os.path.join(BASE_DIR, "backend_auto/all_backend_api", "janus_r
...
@@ -225,7 +225,7 @@ POLYMER_CONFIG = os.path.join(BASE_DIR, "backend_auto/all_backend_api", "janus_r
POLYMER
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/janus_data"
,
"polymer.yaml"
)
POLYMER
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/janus_data"
,
"polymer.yaml"
)
THIRD_PHONE_LOGIN_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"thirdphonelogin_request"
)
THIRD_PHONE_LOGIN_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"thirdphonelogin_request"
)
THIRD_PHONE_LOGIN
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/account_data"
,
"login_thirdphone"
)
THIRD_PHONE_LOGIN
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/account_data"
,
"login_thirdphone
.yaml
"
)
...
@@ -269,6 +269,29 @@ CONVERSATIONDIARY=os.path.join(BASE_DIR, "backend_auto/test_doctor_data/web_data
...
@@ -269,6 +269,29 @@ CONVERSATIONDIARY=os.path.join(BASE_DIR, "backend_auto/test_doctor_data/web_data
CONVERSATIONCOUPON
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_doctor_data/web_data"
,
"conversation_coupon.yaml"
)
CONVERSATIONCOUPON
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_doctor_data/web_data"
,
"conversation_coupon.yaml"
)
#更美次卡橱窗组件商品
VISUAL_BEAUTY_CARD_SERVICES_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"visual_beauty_card.yaml"
)
VISUAL_BEAUTY_CARD_SERVICES
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/visual_beauty_card_data"
,
"visual_beauty_card_services.yaml"
)
#次卡商品列表组件筛选器
BEAUTYCARD_FILTERS_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"visual_beauty_card.yaml"
)
BEAUTYCARD_FILTERS
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/visual_beauty_card_data"
,
"beautycard_filters.yaml"
)
#次卡商品列表组件商品
BEAUTYCARD_SKUS_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"visual_beauty_card.yaml"
)
BEAUTYCARD_SKUS
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/visual_beauty_card_data"
,
"beautycard_skus.yaml"
)
#普通美购提交订单页
PREVIEW_V1
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"settlement_request.yaml"
)
WECHAT_PAY
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"pay_request.yaml"
)
PREVIEW
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/settlement_data"
,
"preview_v1.yaml"
)
PAY_V1
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/settlement_data"
,
"pay_v1.yaml"
)
CREATE
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/settlement_data"
,
"create_v1.yaml"
)
PAY
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/settlement_data"
,
"pay.yaml"
)
WECHARTPAYDATA
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/pay_data"
,
"wechat_prepay.yaml"
)
if
__name__
==
'__main__'
:
if
__name__
==
'__main__'
:
print
(
"=========="
,
LIVEYAML_CONFIG
)
print
(
"=========="
,
LIVEYAML_CONFIG
)
test_backend_case/account_case/test_thirdPhone_login.py
View file @
0b0be6e5
...
@@ -14,7 +14,7 @@ class TestThirdPhoneLogin:
...
@@ -14,7 +14,7 @@ class TestThirdPhoneLogin:
def
test_thirdphone_login
(
self
,
param
):
def
test_thirdphone_login
(
self
,
param
):
r
=
thirdphonelogin_request
()
.
thirdphone_login
(
param
[
"version"
],
param
[
"phone_data"
],
param
[
"phone_from_type"
])
r
=
thirdphonelogin_request
()
.
thirdphone_login
(
param
[
"version"
],
param
[
"phone_data"
],
param
[
"phone_from_type"
])
print
(
'______'
,
r
)
if
r
[
"error"
]
==
1
:
if
r
[
"error"
]
==
1
:
assert
r
[
'message'
]
==
param
[
"assert"
]
assert
r
[
'message'
]
==
param
[
"assert"
]
\ No newline at end of file
test_backend_case/pay_case/__init__.py
0 → 100644
View file @
0b0be6e5
test_backend_case/pay_case/test_wechat_prepay.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.pay_request
import
pay_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
class
TestWechatPrepay
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
WECHARTPAYDATA
)
wechart_case
,
wechart_data
=
get_ids
(
data
,
"wechart_pay"
)
@pytest.mark.parametrize
(
"param"
,
wechart_data
,
ids
=
wechart_case
)
def
test_wechart_prepay
(
self
,
param
):
pass
# r = pay_request().wechat_prepay()
# print(r)
# assert r["error"] == param["assert"]
test_backend_case/settlement_case/__init__.py
0 → 100644
View file @
0b0be6e5
test_backend_case/settlement_case/test_create_v1.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.settlement_request
import
settlement_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
class
TestCreateV1
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
CREATE
)
create_case
,
create_data
=
get_ids
(
data
,
"create_v1"
)
print
(
create_data
)
@pytest.mark.parametrize
(
"param"
,
create_data
,
ids
=
create_case
)
def
test_create_v1
(
self
,
param
):
r
=
settlement_request
()
.
create_v1
(
param
[
"service_item_id"
],
param
[
"number"
],
param
[
"platform_coupon_id"
],
param
[
"use_point"
],
param
[
"is_doctor_see"
],
param
[
"doctor_coupon_id"
],
param
[
"insurance_info"
],
param
[
"is_create_groupbuy"
])
print
(
r
)
assert
r
[
"error"
]
==
param
[
"assert"
]
test_backend_case/settlement_case/test_pay.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.settlement_request
import
settlement_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
class
TestPay
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
PAY
)
pay_case
,
pay_data
=
get_ids
(
data
,
"pay"
)
@pytest.mark.parametrize
(
"param"
,
pay_data
,
ids
=
pay_case
)
def
test_pay
(
self
,
param
):
pay_r
=
settlement_request
()
.
create_v1
(
param
[
"service_item_id"
],
param
[
"number"
],
param
[
"platform_coupon_id"
],
param
[
"use_point"
],
param
[
"is_doctor_see"
],
param
[
"doctor_coupon_id"
],
param
[
"insurance_info"
],
param
[
"is_create_groupbuy"
])
id
=
pay_r
[
"data"
][
"id"
]
r
=
settlement_request
()
.
pay
(
id
)
assert
r
[
"error"
]
==
param
[
"assert"
]
test_backend_case/settlement_case/test_pay_v1.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.settlement_request
import
settlement_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
class
TestPayV1
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
PAY_V1
)
pay_case
,
pay_data
=
get_ids
(
data
,
"pay_v1"
)
@pytest.mark.parametrize
(
"param"
,
pay_data
,
ids
=
pay_case
)
def
test_pay_v1
(
self
,
param
):
r
=
settlement_request
()
.
pay_v1
(
param
[
"actual_pay"
],
param
[
"payment_final_price"
],
param
[
"is_contains_groupbuy_order"
],
param
[
"mul_orders_number"
])
print
(
r
)
assert
r
[
"error"
]
==
param
[
"assert"
]
test_backend_case/settlement_case/test_preview_v1.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.settlement_request
import
settlement_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
class
TestPreviewV1
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
PREVIEW
)
preview_case
,
preview_data
=
get_ids
(
data
,
"preview_v1"
)
@pytest.mark.parametrize
(
"param"
,
preview_data
,
ids
=
preview_case
)
def
test_preview_v1
(
self
,
param
):
r
=
settlement_request
()
.
preview_v1
(
param
[
"current_city_id"
],
param
[
"service_item_id"
],
param
[
"number"
],
param
[
"use_platform_coupon"
],
param
[
"use_doctor_coupon"
],
param
[
"use_coupon_grey"
],
param
[
"is_create_groupbuy"
])
print
(
r
)
assert
r
[
"error"
]
==
param
[
"assert"
]
test_backend_case/visual_beauty_card_case/__init__.py
0 → 100644
View file @
0b0be6e5
test_backend_case/visual_beauty_card_case/test_beautycard_filters.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.visual_beauty_card
import
visual_beauty_card_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
#次卡商品列表筛选器接口
class
TestBeautyCardFilters
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
BEAUTYCARD_FILTERS
)
beautycard_filters_case
,
beautycard_filters_data
=
get_ids
(
data
,
"beautycard_filters"
)
@pytest.mark.parametrize
(
"param"
,
beautycard_filters_data
,
ids
=
beautycard_filters_case
)
def
test_beautycard_filters
(
self
,
param
):
print
(
'次卡商品列表筛选器'
)
r
=
visual_beauty_card_request
()
.
beautycard_filters
(
param
[
"unit_id"
],
param
[
"current_city_id"
],
param
[
"version"
])
if
r
[
"data"
]:
print
(
'次卡商品列表筛选器下拉列表有值'
)
assert
len
(
r
[
"data"
][
"field"
])
!=
param
[
"assert"
]
assert
len
(
r
[
"data"
][
"areas"
])
!=
param
[
"assert"
]
assert
len
(
r
[
"data"
][
"order"
])
!=
param
[
"assert"
]
\ No newline at end of file
test_backend_case/visual_beauty_card_case/test_beautycard_skus.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.visual_beauty_card
import
visual_beauty_card_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
#次卡商品列表组件商品
class
TestBeautyCardSkus
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
BEAUTYCARD_SKUS
)
beautycard_skus_case
,
beautycard_skus_data
=
get_ids
(
data
,
"beautycard_skus"
)
@pytest.mark.parametrize
(
"param"
,
beautycard_skus_data
,
ids
=
beautycard_skus_case
)
def
test_beautycard_skus
(
self
,
param
):
print
(
'次卡商品列表组件商品'
)
r
=
visual_beauty_card_request
()
.
beautycard_skus
(
param
[
"unit_id"
],
param
[
"tag_id"
],
param
[
"area"
],
param
[
"sort_type"
],
param
[
"page"
],
param
[
"page_size"
])
if
r
[
"data"
]:
print
(
'次卡商品列表组件有商品召回'
)
assert
len
(
r
[
"data"
][
"beautycards"
])
!=
param
[
"assert"
]
\ No newline at end of file
test_backend_case/visual_beauty_card_case/test_visual_beauty_card_services.py
0 → 100644
View file @
0b0be6e5
import
pytest
import
path_setting
from
all_backend_api.visual_beauty_card
import
visual_beauty_card_request
from
ids_list
import
get_ids
from
in_common.base_request
import
BaseRequest
#次卡橱窗商品
class
TestVisualBeautyCardServices
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
VISUAL_BEAUTY_CARD_SERVICES
)
visual_beauty_card_services_case
,
visual_beauty_card_services_data
=
get_ids
(
data
,
"visual_beauty_card_services"
)
@pytest.mark.parametrize
(
"param"
,
visual_beauty_card_services_data
,
ids
=
visual_beauty_card_services_case
)
def
test_visual_beauty_card_services
(
self
,
param
):
print
(
'次卡橱窗'
)
r
=
visual_beauty_card_request
()
.
visual_beauty_card_services
(
param
[
"unit_id"
],
param
[
"current_city_id"
],
param
[
"page"
],
param
[
"page_size"
],
param
[
"version"
])
if
r
[
"data"
][
"beautycards"
]:
print
(
'次卡橱窗有商品'
)
assert
len
(
r
[
"data"
][
"beautycards"
])
!=
param
[
"assert"
]
\ No newline at end of file
test_backend_data/account_data/login_thirdphone
→
test_backend_data/account_data/login_thirdphone
.yaml
View file @
0b0be6e5
login_thirdphone
:
login_thirdphone
:
- case: "无版本号手机号一键登录case"
-
case
:
"
无版本号手机号一键登录case"
phone_data
:
'
{
phone_data
:
'
{
"token"
:
"A4-lVEf_Fk2ekkxSFgSZ59yD6bPaIxHWzJfsGgaEBDrbZzFyxMueOODIoBeXXQuHU8REjG42jvyjQa2a3rkDm8ufKlI8DL3ny2FfxnUrnuQOycWRaHKN3664onbOetr54dvb4wkVaV7X33yBlw7u_ZCNqIOwTnRQ9kPgHDBpvyN4NTdYYf2tJWhF4VeiVOqc7OiRz-Nzt08AUvbtWpw6sPQjA==",
"token"
:
"A4-lVEf_Fk2ekkxSFgSZ59yD6bPaIxHWzJfsGgaEBDrbZzFyxMueOODIoBeXXQuHU8REjG42jvyjQa2a3rkDm8ufKlI8DL3ny2FfxnUrnuQOycWRaHKN3664onbOetr54dvb4wkVaV7X33yBlw7u_ZCNqIOwTnRQ9kPgHDBpvyN4NTdYYf2tJWhF4VeiVOqc7OiRz-Nzt08AUvbtWpw6sPQjA==",
"appId"
:
"xK5yFMfJ"
"appId"
:
"xK5yFMfJ"
...
@@ -9,7 +10,8 @@ login_thirdphone:
...
@@ -9,7 +10,8 @@ login_thirdphone:
version
:
version
:
assert
:
"
获取手机号失败"
assert
:
"
获取手机号失败"
- case: "大于7.32手机号一键登录case"
-
case
:
"
大于7.32手机号一键登录case"
phone_data
:
'
{
phone_data
:
'
{
"token"
:
"A4-lVEf_Fk2ekkxSFgSZ59yD6bPaIxHWzJfsGgaEBDrbZzFyxMueOODIoBeXXQuHU8REjG42jvyjQa2a3rkDm8ufKlI8DL3ny2FfxnUrnuQOycWRaHKN3664onbOetr54dvb4wkVaV7X33yBlw7u_ZCNqIOwTnRQ9kPgHDBpvyN4NTdYYf2tJWhF4VeiVOqc7OiRz-Nzt08AUvbtWpw6sPQjA==",
"token"
:
"A4-lVEf_Fk2ekkxSFgSZ59yD6bPaIxHWzJfsGgaEBDrbZzFyxMueOODIoBeXXQuHU8REjG42jvyjQa2a3rkDm8ufKlI8DL3ny2FfxnUrnuQOycWRaHKN3664onbOetr54dvb4wkVaV7X33yBlw7u_ZCNqIOwTnRQ9kPgHDBpvyN4NTdYYf2tJWhF4VeiVOqc7OiRz-Nzt08AUvbtWpw6sPQjA==",
"appId"
:
"xK5yFMfJ"
"appId"
:
"xK5yFMfJ"
...
@@ -18,7 +20,8 @@ login_thirdphone:
...
@@ -18,7 +20,8 @@ login_thirdphone:
version
:
"
7.43.0"
version
:
"
7.43.0"
assert
:
"
获取手机号失败"
assert
:
"
获取手机号失败"
- case: "小于7.32手机号一键登录case"
-
case
:
"
小于7.32手机号一键登录case"
phone_data
:
'
{
phone_data
:
'
{
"token"
:
"A4-lVEf_Fk2ekkxSFgSZ59yD6bPaIxHWzJfsGgaEBDrbZzFyxMueOODIoBeXXQuHU8REjG42jvyjQa2a3rkDm8ufKlI8DL3ny2FfxnUrnuQOycWRaHKN3664onbOetr54dvb4wkVaV7X33yBlw7u_ZCNqIOwTnRQ9kPgHDBpvyN4NTdYYf2tJWhF4VeiVOqc7OiRz-Nzt08AUvbtWpw6sPQjA==",
"token"
:
"A4-lVEf_Fk2ekkxSFgSZ59yD6bPaIxHWzJfsGgaEBDrbZzFyxMueOODIoBeXXQuHU8REjG42jvyjQa2a3rkDm8ufKlI8DL3ny2FfxnUrnuQOycWRaHKN3664onbOetr54dvb4wkVaV7X33yBlw7u_ZCNqIOwTnRQ9kPgHDBpvyN4NTdYYf2tJWhF4VeiVOqc7OiRz-Nzt08AUvbtWpw6sPQjA==",
"appId"
:
"xK5yFMfJ"
"appId"
:
"xK5yFMfJ"
...
...
test_backend_data/pay_data/__init__.py
0 → 100644
View file @
0b0be6e5
test_backend_data/pay_data/wechat_prepay.yaml
0 → 100644
View file @
0b0be6e5
wechart_pay
:
-
case
:
"
普通美购订单支付流程--微信支付"
assert
:
0
test_backend_data/settlement_data/__init__.py
0 → 100644
View file @
0b0be6e5
test_backend_data/settlement_data/create_v1.yaml
0 → 100644
View file @
0b0be6e5
create_v1
:
-
case
:
"
普通美购下单--获取支付类型接口"
service_item_id
:
599428
number
:
1
platform_coupon_id
:
"
"
use_point
:
0
is_doctor_see
:
1
doctor_coupon_id
:
"
"
insurance_info
:
"
[]"
is_create_groupbuy
:
0
assert
:
0
test_backend_data/settlement_data/pay.yaml
0 → 100644
View file @
0b0be6e5
pay
:
-
case
:
"
普通美购下单流程--生成支付金额等信息"
service_item_id
:
599428
number
:
1
platform_coupon_id
:
"
"
use_point
:
0
is_doctor_see
:
1
doctor_coupon_id
:
"
"
insurance_info
:
"
[]"
is_create_groupbuy
:
0
assert
:
0
\ No newline at end of file
test_backend_data/settlement_data/pay_v1.yaml
0 → 100644
View file @
0b0be6e5
pay_v1
:
-
case
:
"
普通美购下单流程--获取支付类型接口"
actual_pay
:
656
payment_final_price
:
2624
is_contains_groupbuy_order
:
"
false"
mul_orders_number
:
"
false"
assert
:
0
test_backend_data/settlement_data/preview_v1.yaml
0 → 100644
View file @
0b0be6e5
preview_v1
:
-
case
:
"
普通美购下单流程--确认订单页面sucess"
current_city_id
:
"
beijing"
service_item_id
:
599428
number
:
1
use_platform_coupon
:
1
use_doctor_coupon
:
1
use_coupon_grey
:
"
true"
is_create_groupbuy
:
0
assert
:
0
\ No newline at end of file
test_backend_data/visual_beauty_card_data/__init__.py
0 → 100644
View file @
0b0be6e5
test_backend_data/visual_beauty_card_data/beautycard_filters.yaml
0 → 100644
View file @
0b0be6e5
beautycard_filters
:
-
#更美次卡商品列表组件筛选器-按SPU导入,筛选器接口正常
case
:
"
更美次卡商品列表组件筛选器-按SPU导入,筛选器接口正常"
unit_id
:
"
20109"
current_city_id
:
"
beijing"
version
:
"
743.0"
assert
:
0
-
#更美次卡商品列表组件筛选器-按SKU导入,筛选器接口正常
case
:
"
更美次卡商品列表组件筛选器-按SKU导入,筛选器接口正常"
unit_id
:
"
20113"
current_city_id
:
"
beijing"
version
:
"
743.0"
assert
:
0
\ No newline at end of file
test_backend_data/visual_beauty_card_data/beautycard_skus.yaml
0 → 100644
View file @
0b0be6e5
beautycard_skus
:
-
#更美次卡商品列表组件商品-按SPU导入,商品默认排序
case
:
"
更美次卡商品列表组件商品-按SPU导入,商品默认排序"
unit_id
:
"
20109"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
0"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SKU导入,商品默认排序
case
:
"
更美次卡商品列表组件商品-按SKU导入,商品默认排序"
unit_id
:
"
20113"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
0"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SPU导入,商品价格最低
case
:
"
更美次卡商品列表组件商品-按SPU导入,商品价格最低"
unit_id
:
"
20110"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
2"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SKU导入,商品价格最低
case
:
"
更美次卡商品列表组件商品-按SKU导入,商品价格最低"
unit_id
:
"
20114"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
2"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SPU导入,商品销量最高
case
:
"
更美次卡商品列表组件商品-按SPU导入,商品销量最高"
unit_id
:
"
20111"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
1"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SKU导入,商品销量最高
case
:
"
更美次卡商品列表组件商品-按SKU导入,商品销量最高"
unit_id
:
"
20115"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
1"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SPU导入,商品最新上架
case
:
"
更美次卡商品列表组件商品-按SPU导入,商品最新上架"
unit_id
:
"
20112"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
3"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SKU导入,商品最新上架
case
:
"
更美次卡商品列表组件商品-按SKU导入,商品最新上架"
unit_id
:
"
20116"
tag_id
:
"
-1"
area
:
"
worldwide"
sort_type
:
"
3"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SPU导入,修改城市筛选器为北京,商品正常召回
case
:
"
更美次卡商品列表组件商品-按SPU导入,修改城市筛选器为北京,商品正常召回"
unit_id
:
"
20110"
tag_id
:
"
-1"
area
:
"
beijing"
sort_type
:
"
2"
page
:
"
0"
page_size
:
"
20"
assert
:
0
-
#更美次卡商品列表组件商品-按SKU导入,修改城市筛选器为北京,商品正常召回
case
:
"
更美次卡商品列表组件商品-按SKU导入,修改城市筛选器为北京,商品正常召回"
unit_id
:
"
20115"
tag_id
:
"
-1"
area
:
"
beijing"
sort_type
:
"
1"
page
:
"
0"
page_size
:
"
20"
assert
:
0
test_backend_data/visual_beauty_card_data/visual_beauty_card_services.yaml
0 → 100644
View file @
0b0be6e5
visual_beauty_card_services
:
-
#更美次卡橱窗-按SPU导入,定位北京,商品正常召回
case
:
"
更美次卡橱窗-按SPU导入,定位北京,商品正常召回"
unit_id
:
"
20105"
current_city_id
:
"
beijing"
page
:
"
0"
page_size
:
"
50"
version
:
"
743.0"
assert
:
0
-
#更美次卡橱窗-按SKU导入,定位北京,商品正常召回
case
:
"
更美次卡橱窗-按SKU导入,定位北京,商品正常召回"
unit_id
:
"
20106"
current_city_id
:
"
beijing"
page
:
"
0"
page_size
:
"
50"
version
:
"
743.0"
assert
:
0
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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