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
79afc43c
Commit
79afc43c
authored
Jul 07, 2021
by
张淑琴
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
点点通内容概览
parent
6e024e68
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
53 additions
and
3 deletions
+53
-3
web_request.py
all_doctor_api/web_request.py
+6
-2
web_request.yaml
all_doctor_api/web_request.yaml
+9
-0
path_setting.py
path_setting.py
+2
-0
test_artemis_order_list.py
test_doctor_case/web_case/test_artemis_order_list.py
+2
-0
test_cpc_community_homepage.py
test_doctor_case/web_case/test_cpc_community_homepage.py
+23
-0
artemis_order_list.yaml
test_doctor_data/web_data/artemis_order_list.yaml
+2
-1
cpc_community_homepage.yaml
test_doctor_data/web_data/cpc_community_homepage.yaml
+9
-0
No files found.
all_doctor_api/web_request.py
View file @
79afc43c
...
...
@@ -72,6 +72,9 @@ class web_request(BaseRequest):
def
artemis_order_id_detail
(
self
):
"上线中订单详情页"
return
self
.
api_send
(
self
.
ACCOUNT_URL
[
"artemis_order_id_detail"
])
def
cpc_community_homepage
(
self
):
"点点通-内容-概览"
return
self
.
api_send
(
self
.
ACCOUNT_URL
[
"cpc_community_homepage"
])
...
...
@@ -96,4 +99,5 @@ if __name__ == '__main__':
print
(
web_request
()
.
artemis_order_list
(
0
,
1
))
print
(
web_request
()
.
artemis_order_list
(
1
,
1
))
print
(
web_request
()
.
artemis_order_list
(
2
,
1
))
print
(
web_request
()
.
artemis_order_id_detail
())
\ No newline at end of file
print
(
web_request
()
.
artemis_order_id_detail
())
print
(
web_request
()
.
cpc_community_homepage
())
\ No newline at end of file
all_doctor_api/web_request.yaml
View file @
79afc43c
...
...
@@ -153,4 +153,12 @@ artemis_order_id_detail:
params
:
{}
data
:
{}
json
:
{}
isLogin
:
1
#需要登录
cpc_community_homepage
:
method
:
get
url
:
/api/web/cpc_community/homepage
params
:
{}
data
:
{}
json
:
{}
isLogin
:
1
#需要登录
\ No newline at end of file
path_setting.py
View file @
79afc43c
...
...
@@ -435,6 +435,8 @@ VALUEORDERIDDETAIL=os.path.join(BASE_DIR, "backend_auto/test_doctor_data/web2_da
ADPACKAGEORDERDETAIL
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_doctor_data/web2_data"
,
"artemis_ad_packageorder_detail.yaml"
)
#医生后台-点点通商品-概览
CPCHOMEPAGE
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_doctor_data/web_data"
,
"cpc_homepage.yaml"
)
#医生后台-点点通内容-概览
CPCCOMMUNITYHOMEPAGE
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_doctor_data/web_data"
,
"cpc_community_homepage.yaml"
)
#更美次卡橱窗组件商品
VISUAL_BEAUTY_CARD_SERVICES_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"visual_beauty_card.yaml"
)
...
...
test_doctor_case/web_case/test_artemis_order_list.py
View file @
79afc43c
...
...
@@ -18,4 +18,6 @@ class TestArtemisOrderList:
if
r
[
"error"
]
==
0
:
orders
=
r
.
get
(
"data"
)
.
get
(
"orders"
,
[])
assert
len
(
orders
)
>=
param
[
"assert"
]
if
r
[
"error"
]
==
300002
:
assert
r
[
"message"
]
==
param
[
"assert_message"
]
test_doctor_case/web_case/test_cpc_community_homepage.py
0 → 100644
View file @
79afc43c
import
pytest
from
ids_list
import
get_ids
import
path_setting
from
in_common.base_request
import
BaseRequest
from
all_doctor_api.web_request
import
web_request
class
TestCpcCommunityHomepage
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
CPCCOMMUNITYHOMEPAGE
)
cpccommunityhomepage_case
,
cpccommunityhomepage_data
=
get_ids
(
data
,
"cpc_community_homepage"
)
@pytest.mark.parametrize
(
"param"
,
cpccommunityhomepage_data
,
ids
=
cpccommunityhomepage_case
)
def
test_cpc_community_homepage
(
self
,
param
):
'''点点通-概览'''
r
=
web_request
()
.
cpc_community_homepage
()
if
r
[
"error"
]
==
0
:
if
r
[
"data"
][
"account"
]
<=
"0"
:
assert
r
[
"data"
][
"is_cpc"
]
==
param
[
"assert"
]
else
:
assert
r
[
"data"
][
"is_cpc"
]
==
param
[
"assert1"
]
test_doctor_data/web_data/artemis_order_list.yaml
View file @
79afc43c
artemis_order_list
:
#我的服务订单case
-
case
:
"
我的服务订单
请求失败
case"
case
:
"
我的服务订单
参数错误
case"
status
:
"
"
page
:
1
assert
:
0
assert_message
:
"
错误参数:
status"
-
case
:
"
我的服务订单-待支付广告包case"
status
:
0
...
...
test_doctor_data/web_data/cpc_community_homepage.yaml
0 → 100644
View file @
79afc43c
cpc_community_homepage
:
#点点通内容-概览case
-
case
:
"
点点通内容概览"
#doctor_user_id: "602329"
assert
:
False
assert_account
:
0
assert1
:
True
\ 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