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
35663fd0
You need to sign in or sign up before continuing.
Commit
35663fd0
authored
Jun 02, 2021
by
张淑琴
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
全部私信
parent
c26aa0ea
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
56 additions
and
2 deletions
+56
-2
web_request.py
all_doctor_api/web_request.py
+7
-0
web_request.yaml
all_doctor_api/web_request.yaml
+10
-0
host.yaml
host.yaml
+2
-2
path_setting.py
path_setting.py
+4
-0
test_conversation.py
test_doctor_case/web_case/test_conversation.py
+22
-0
conversation.yaml
test_doctor_data/web_data/conversation.yaml
+11
-0
No files found.
all_doctor_api/web_request.py
View file @
35663fd0
...
...
@@ -15,6 +15,11 @@ class web_request(BaseRequest):
def
doctor_submechanisms
(
self
)
:
return
self
.
api_send
(
self
.
data
[
"doctor_submechanisms"
])
def
conversation
(
self
,
is_star
,
page
):
self
.
params
[
"is_star"
]
=
is_star
self
.
params
[
"page"
]
=
page
return
self
.
api_send
(
self
.
data
[
"conversation"
])
...
...
@@ -24,3 +29,5 @@ if __name__ == '__main__':
print
(
web_request
()
.
account_unreadbadgecount
())
print
(
web_request
()
.
article_videotoken
())
print
(
web_request
()
.
doctor_submechanisms
())
print
(
"列表页"
)
print
(
web_request
()
.
conversation
(
0
,
1
))
all_doctor_api/web_request.yaml
View file @
35663fd0
...
...
@@ -27,3 +27,13 @@ doctor_submechanisms:
isLogin
:
1
conversation
:
method
:
get
url
:
/api/web/conversation
param
:
is_star
:
${is_star}
page
:
${page}
data
:
{}
json
:
{}
isLogin
:
1
#需要登录
host.yaml
View file @
35663fd0
develop_host
:
backend
:
http://backend.paas-develop.env
#
doctor: http://doctor.paas-develop.env
#
backend: http://backend.paas-develop.env
doctor
:
http://doctor.paas-develop.env
path_setting.py
View file @
35663fd0
...
...
@@ -180,5 +180,9 @@ CANCEL_VOTE = os.path.join(BASE_DIR, "backend_auto/test_backend_data/answer_data
QUESTION_CONFIG
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/all_backend_api"
,
"question_request.yaml"
)
REPLY_ANSWER
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_backend_data/question_data"
,
"reply_answer.yaml"
)
#医生后台--全部私信列表
CONVERSATION
=
os
.
path
.
join
(
BASE_DIR
,
"backend_auto/test_doctor_data/web_data"
,
"conversation.yaml"
)
if
__name__
==
'__main__'
:
print
(
"=========="
,
LIVEYAML_CONFIG
)
test_doctor_case/web_case/test_conversation.py
0 → 100644
View file @
35663fd0
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
TestConversation
:
data
=
BaseRequest
()
.
api_load
(
path_setting
.
CONVERSATION
)
conversation_case
,
conversation_data
=
get_ids
(
data
,
"conversation"
)
@pytest.mark.parametrize
(
"param"
,
conversation_data
,
ids
=
conversation_case
)
def
test_conversation
(
self
,
param
):
'''私信列表'''
r
=
web_request
()
.
conversation
(
param
[
"is_star"
],
param
[
"page"
])
if
r
[
"error"
]
==
0
:
conversation
=
r
.
get
(
"data"
)
.
get
(
"conversation"
,
[])
assert
len
(
conversation
)
<=
param
[
"assert"
]
assert
r
[
"data"
][
"size"
]
<=
param
[
"assert_size"
]
test_doctor_data/web_data/conversation.yaml
0 → 100644
View file @
35663fd0
conversation
:
#全部私信case
-
case
:
"
请求成功,有数据返回的第一页数据"
is_star
:
0
page
:
1
assert_size
:
10
assert
:
10
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