作者 dengyuting

fix

正在显示 116 个修改的文件 包含 2696 行增加1592 行删除
adminphone=19911111111
phone1=19999990001
phone2=19999990002
phone3=19999990003
wpftwphone=19990000008
pfphone=19990000011
pfphone1=19990000015
... ... @@ -5,7 +9,8 @@ wtaskphone=19999999999
appphone1=19990000014
appphone=19990000015
password=123456
base_url=https://ability-test.fjmaimaimai.com
base_public_url = http://public-interface-test.fjmaimaimai.com/
base_business_url = https://suplus-business-admin-gateway-test.fjmaimaimai.com/
base_worth_url = https://suplus-worth-web-gateway-test.fjmaimaimai.com/
\ No newline at end of file
base_url=https://suplus-worth-app-gateway-test.fjmaimaimai.com
base_ucenter = http://public-interface-test.fjmaimaimai.com
base_business_admin = https://suplus-business-admin-gateway-test.fjmaimaimai.com
base_manager_url = https://suplus-worth-web-gateway-test.fjmaimaimai.com
companyid=214
\ No newline at end of file
... ...
name: 发布提问
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
title: 最有价值测试${get_second()}
content: 最有价值测试${get_second()}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: abilityIOSTest/1000012 CFNetwork/1121.2.2 Darwin/19.3.0
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 1.0.0
json:
content: $content
id: 0
initDep:
id: 101229
name: 食品
pictures:
- h: 1334
path: http://ability-test.fjmaimaimai.com:8899/html/ab/1586654116769645740.jpg
w: 750
relatedDeps:
- id: 101229
name: 食品
selected: true
title: $title
way: 1
method: POST
url: /v1/question/addQuestion
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 发布成功
name: 首页BOSS足迹:/v1/question/bossFootprints
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '1'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.4.0
json: {}
method: POST
url: /v1/question/bossFootprints
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取BOSS足迹成功
\ No newline at end of file
... ... @@ -2,29 +2,27 @@ name: 获取授权令牌
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ''
sign: ${make_sign($currtime, $uuid,$access_token)}
teardown_hooks:
- ${teardown_hook_get_task_accesstoken($response)}
currtime2: ${make_time()}
uuid2: ${make_uuid()}
access_token2: ''
sign2: ${make_sign($currtime2, $uuid2,$access_token2)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: abilityIOSTest/120004 CFNetwork/1121.2.2 Darwin/19.3.0
# X-MMM-AppName: com.maimaimai.abilityIOS
X-MMM-AppProject: ability
X-MMM-AccessToken: $access_token2
X-MMM-DeviceType: "0"
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Sign: $sign2
X-MMM-Timestamp: $currtime2
X-MMM-Uuid: $uuid2
X-MMM-Version: 0.12.0
json:
clientId: lks3Z8Ncn2j
authCode: ${get_task_authcode()}
authCode: ${get_authcode()}
clientSecret: gtfhyjukiol3Qncbvmdwe67khh
method: POST
url: v1/auth/accessToken
url: /v1/auth/accessToken
validate:
- eq:
- content.code
... ...
name: /api/time/get_timestamp
request:
headers:
User-Agent: okhttp/3.12.3
method: GET
url: http://tongji.fjmaimaimai.com/api/time/get_timestamp
validate:
- eq:
- content.msg
- success
- eq:
- content.code
- 0
\ No newline at end of file
name: 客户端账号登录
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ''
sign: ${make_sign($currtime, $uuid,$access_token)}
phone: ${ENV(wpftwphone)}
teardown_hooks:
- ${teardown_hook_get_authcode($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: abilityIOSTest/120004 CFNetwork/1121.2.2 Darwin/19.3.0
X-MMM-AppName: com.maimaimai.abilityIOS
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json:
clientId: lks3Z8Ncn2j
credentials: ${get_credentials()}
cuid: ${get_cuid()}
muid: ${get_muid()}
cid: ${get_cid()}
method: POST
url: v1/auth/authorize
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 登录成功
name: 登录价值系统
base_url: ${ENV(base_url)}
verify: False
#teardown_hooks:
# - ${teardown_hook_get_authcode($response)}
variables:
currtime1: ${make_time()}
uuid1: ${make_uuid()}
access_token1: ''
sign1: ${make_sign($currtime1, $uuid1,$access_token1)}
credentials: $credentials
cuid: $cuid
muid: $muid
cid: ${ENV(companyid)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: abilityIOSTest/120004 CFNetwork/1121.2.2 Darwin/19.3.0
X-MMM-AppName: com.maimaimai.abilityIOS
X-MMM-AccessToken: $access_token1
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign1
X-MMM-Timestamp: $currtime1
X-MMM-Uuid: $uuid1
X-MMM-Version: 0.12.0
json:
clientId: lks3Z8Ncn2j
credentials: $credentials
cuid: $cuid
muid: $muid
cid: ${ENV(companyid)}
method: POST
url: /v1/auth/authorize
extract:
authCode: content.data.authCode
validate:
- eq:
- content.code
- 0
... ...
name: 登录价值系统
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ''
sign: ${make_sign($currtime, $uuid,$access_token)}
phone: ${ENV(wpftwphone)}
teardown_hooks:
- ${teardown_hook_get_task_authcode($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: abilityIOSTest/120004 CFNetwork/1121.2.2 Darwin/19.3.0
X-MMM-AppName: com.maimaimai.abilityIOS
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json:
clientId: lks3Z8Ncn2j
credentials: ${get_credentials()}
cuid: ${get_cuid()}
muid: ${get_muid()}
cid: ${get_cid()}
method: POST
url: v1/auth/authorize
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 登录成功
name: 用户中心账号登录
base_url: ${ENV(base_public_url)}
name: 账号登录:/auth/loginAggregate
base_url: ${ENV(base_ucenter)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ''
sign: ${make_sign($currtime, $uuid,$access_token)}
grantType: signInPassword
phone: ${ENV(appphone)}
phone: ${ENV(adminphone)}
password: 7c4a8d09ca3762af61e59520943dc26494f8941b
Type: 1
msg: ok
teardown_hooks:
- ${teardown_hook_get_cuid($response)}
- ${teardown_hook_get_credentials($response)}
- ${teardown_hook_get_muid($response)}
- ${teardown_hook_get_cid($response)}
#teardown_hooks:
# - ${teardown_hook_get_authcode($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token
X-MMM-DeviceType: '1'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.9.0
json:
grantType: $grantType
... ... @@ -33,11 +21,12 @@ request:
phone: $phone
clientId: lks3Z8Ncn2j
method: POST
url: ucenter/v2/auth/loginAggregate
url: /ucenter/v2/auth/loginAggregate
extract:
# cuid: content.data.cuid
cuid: content.data.cuid
credentials: content.data.credentials
muid: content.data.companys.0.muid
validate:
- eq:
- content.msg
- ok
- $msg
... ...
name: 获取授权令牌
name: 获取用户信息
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ''
sign: ${make_sign($currtime, $uuid,$access_token)}
teardown_hooks:
- ${teardown_hook_get_accesstoken($response)}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: abilityIOSTest/120004 CFNetwork/1121.2.2 Darwin/19.3.0
X-MMM-AccessToken: $access_token
# X-MMM-AppName: com.maimaimai.abilityIOS
X-MMM-AppProject: ability
X-MMM-DeviceType: "0"
... ... @@ -20,15 +19,10 @@ request:
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json:
clientId: lks3Z8Ncn2j
authCode: ${get_authcode()}
clientSecret: gtfhyjukiol3Qncbvmdwe67khh
clientId: lks3Z8Ncn2jhr
method: POST
url: v1/auth/accessToken
url: /v2/user/userInfo
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取成功
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 待我审核:/v1/question/audits_ireview
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
#output:
# qid: qid
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json:
dids: ''
lastId: 0
pageSize: 20
method: POST
url: /v1/question/audits_ireview
#extract:
# qid: content.data.questions.0.id
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 问题审核列表成功
name: 获取BOSS足迹:/v2/question/bossFootprints
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
var_access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $var_access_token)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $var_access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json:
pageIndex: 0
pageSize: 20
method: POST
url: /v2/question/bossFootprints
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取BOSS足迹成功
name: 查看提问详情:/v2/question/details
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
teardown_hooks:
- ${teardown_hook_get_serialNo($response)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json:
# commentLastId: 0
# commentPageSize: 20
qid: $qid
method: POST
url: /v2/question/details
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取问题详情成功
\ No newline at end of file
name: 公司悬赏任务
name: 任务统计
base_url: ${ENV(base_url)}
verify: False
variables:
... ... @@ -19,17 +19,10 @@ request:
X-MMM-Uuid: $uuid
X-MMM-Version: 1.0.0
json:
pageIndex: 0
pageSize: 20
id: 0
method: POST
url: v1/task/rewards
url: /v1/task/taskStatistics
validate:
- eq:
- content.code
- 0
- eq:
- content.data.tasks.0.id
- $id
- eq:
- content.msg
- 获取成功
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 公司任务(进行中)
name: 个人中心-指派我的
base_url: ${ENV(base_url)}
verify: False
variables:
... ... @@ -6,8 +6,7 @@ variables:
uuid: ${make_uuid()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
action: 0
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -21,16 +20,12 @@ request:
X-MMM-Uuid: $uuid
X-MMM-Version: 1.0.0
json:
action: 0
newest: 0
pageIndex: 0
pageSize: 20
action: $action
method: POST
url: v1/task/currentTasks
url: /v1/task/AssignMeTasks
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取成功
- 0
\ No newline at end of file
... ...
name: 公告列表:/v1/message/announcements
name: 中标
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
id: 12345678
uid: 123456789
planFinishDate: 1603900800000
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -16,14 +20,14 @@ request:
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json: {}
X-MMM-Version: 1.0.0
json:
id: $id
planFinishDate: $planFinishDate
uid: $uid
method: POST
url: /v1/message/announcements
url: /v1/task/bidTask
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取公告信息成功
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 审核提问:/v1/question/auditQuestion
name: 验收任务
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
published: 2
id: 0123456
actualFinishDate: 1568956
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -17,18 +19,27 @@ request:
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
X-MMM-Version: 1.0.0
json:
id: $qid
published: $published
qTypeId: 149
scoreAsk: 0.5
id: $id
actualFinishDate: $actualFinishDate
taskAwards:
- uid: 3284714710070272
uname: '价值系统账号1'
bonus: 90
percent: 90
- uid: 3284714779253760
uname: '价值系统账号3'
bonus: 10
percent: 10
# resourceAwards:
# -
solveReport: '解决方案报告${get_nowtime()}'
# solveImages:
# -
method: POST
url: /v1/question/auditQuestion
url: /v1/task/checkAccept
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 审核成功
- eq:
- content.code
- 0
\ No newline at end of file
... ...
name: 首页搜索:/v1/question/searchAll
name: 任务列表
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
action: 0
newest: 0
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -13,22 +15,28 @@ request:
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '1'
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.5.0
X-MMM-Version: 1.0.0
json:
keyword: ' '
pageIndex: 0
pageSize: 20
solved: 0
action: $action
newest: $newest
# natures:
# - id:
# name:
# attributes:
# - id:
# name:
# csVals:
# - id:
# name:
method: POST
url: /v1/question/searchAll
url: /v1/task/contendTasks
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取提问列表成功
- eq:
- content.code
- 0
\ No newline at end of file
... ...
name: 消息数量统计(首页、个人中心):/v1/message/msgStatistics
name: 完成任务
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
id: 12345678
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -16,15 +18,12 @@ request:
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
X-MMM-Version: 1.0.0
json:
typeTotal: 1835019
id: $id
method: POST
url: /v1/message/msgStatistics
url: /v1/task/finishTask
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取统计信息成功
\ No newline at end of file
- eq:
- content.code
- 0
\ No newline at end of file
... ...
name: 公司任务(进行中)
name: 个人中心-我发布的
base_url: ${ENV(base_url)}
verify: False
variables:
... ... @@ -6,8 +6,8 @@ variables:
uuid: ${make_uuid()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
action: 0
type: [0,1,2]
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -21,19 +21,11 @@ request:
X-MMM-Uuid: $uuid
X-MMM-Version: 1.0.0
json:
action: 0
newest: 0
pageIndex: 0
pageSize: 20
action: $action
type: $type
method: POST
url: v1/task/currentTasks
url: /v1/task/iPublishedTasks
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取成功
# - eq:
# - $task_total1
# - $task_total2
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 公司任务(进行中)
name: 领取任务
base_url: ${ENV(base_url)}
verify: False
variables:
... ... @@ -6,8 +6,8 @@ variables:
uuid: ${make_uuid()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
action: 0
id: 3120540807229604864
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -21,19 +21,11 @@ request:
X-MMM-Uuid: $uuid
X-MMM-Version: 1.0.0
json:
action: 0
newest: 0
pageIndex: 0
pageSize: 20
id: $id
action: $action
method: POST
url: v1/task/currentTasks
url: /v1/task/submitCompete
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 申请解决提问:/v1/question/applyForQuestions
name: 查看任务详情
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
id: 12345678
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -17,15 +18,12 @@ request:
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
X-MMM-Version: 1.0.0
json:
qid: $qid
id: $id
method: POST
url: /v1/question/applyForQuestions
url: /v1/task/taskDetails
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 申请解决成功
- eq:
- content.code
- 0
\ No newline at end of file
... ...
name: 发布任务
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
action: 0
type: 0
bidStartTime:
bidEndTime:
plannedFinishDate:
uid:
uname:
title: 'APP提交任务标题'
content: 'APP提交任务内容'
acceptability: 'APP提交验收标准'
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 1.0.0
json:
id: 0
action: $action
type: $type
title: $title
content: $content
acceptability: $acceptability
# images:
# - path:
# w:
# h:
nature:
id: 16
name: '性质管理1'
csVals:
- id: 36
name: '价值管理1'
bidStartTime: $bidStartTime
bidEndTime: $bidEndTime
bonus: 100
refResources:
rType:
id:
serialNo:
title:
content:
isReward:
attribute:
id: 17
name: '项目归属1'
employees:
uid: $uid
uname: $uname
plannedFinishDate: $plannedFinishDate
deadlineRemind:
method: POST
url: /v1/task/taskPublish
validate:
- eq:
- content.code
- 0
\ No newline at end of file
... ...
name: 首页公告内容:/v1/notice/announcement
name: 确认领取人
base_url: ${ENV(base_url)}
verify: False
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
access_token: ${get_accesstoken()}
access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $access_token)}
taskId: 123456789
planDate: 1603900800000
request:
headers:
Content-Type: application/json;charset=utf-8
... ... @@ -16,14 +19,13 @@ request:
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json: {}
X-MMM-Version: 1.0.0
json:
taskId: $taskId
planDate: $planDate
method: POST
url: /v1/notice/announcement
url: /v1/task/verifyReceiver
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取公告信息成功
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 获取用户信息
base_url: ${ENV(base_url)}
variables:
currtime: ${make_time()}
uuid: ${make_uuid()}
var_access_token: ${get_task_accesstoken()}
sign: ${make_sign($currtime, $uuid, $var_access_token)}
request:
headers:
Content-Type: application/json;charset=utf-8
User-Agent: okhttp/3.12.3
X-MMM-AccessToken: $var_access_token
X-MMM-AppName: com.mmm.ability
X-MMM-AppProject: ability
X-MMM-DeviceType: '0'
X-MMM-Sign: $sign
X-MMM-Timestamp: $currtime
X-MMM-Uuid: $uuid
X-MMM-Version: 0.12.0
json: {}
method: POST
url: v2/user/userInfo
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- 获取用户信息
- eq:
- content.data.user.permissionTaskPublish
- $permissionTaskPublish
\ No newline at end of file
name: 登录公司
base_url: ${ENV(base_business_url)}
base_url: ${ENV(base_business_admin)}
verify: False
teardown_hooks:
- ${teardown_hook_get_access_token($response)}
variables:
companyId: ${ENV(companyId)}
request:
headers:
Content-Type: application/json; charset=UTF-8
Authorization: Bearer ${get_Authorization()}
Authorization: Bearer $pwdLogintoken
Origin: https://enterprise-platform-dev.fjmaimaimai.com
Referer: https://enterprise-platform-dev.fjmaimaimai.com/
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36
... ... @@ -14,11 +14,8 @@ request:
json:
companyId: $companyId
method: POST
url: auth/anonymousLogin
url: /auth/anonymousLogin
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- ok
\ No newline at end of file
- eq:
- content.msg
- ok
\ No newline at end of file
... ...
name: 登录列表
base_url: ${ENV(base_business_url)}
base_url: ${ENV(base_business_admin)}
verify: False
teardown_hooks:
- ${teardown_hook_get_login_code($response)}
request:
headers:
Content-Type: application/json; charset=UTF-8
Authorization: Bearer ${get_access_token()}
Origin: https://enterprise-platform-dev.fjmaimaimai.com
Referer: https://enterprise-platform-dev.fjmaimaimai.com/
Authorization: Bearer $anonymousLogintoken
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36
X-Requested-With: XMLHttpRequest
json:
companyId: 214
method: POST
url: auth/getSingleLoginMenus
url: /auth/getSingleLoginMenus
extract:
url: content.data.list.0.url
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- ok
\ No newline at end of file
- 0
\ No newline at end of file
... ...
name: 登录价值系统
base_url: ${ENV(base_worth_url)}
base_url: ${ENV(base_manager_url)}
verify: False
variables:
secret: ${get_secret($url)}
msg: ok
teardown_hooks:
- ${teardown_hook_get_task_Authorization($response)}
request:
headers:
# Authorization: Bearer ${get_access_token()}
Content-Type: application/json; charset=UTF-8
Origin: https://enterprise-platform-dev.fjmaimaimai.com
Referer: https://enterprise-platform-dev.fjmaimaimai.com/
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.75 Safari/537.36
X-Requested-With: XMLHttpRequest
json:
code: ${get_login_code()}
code: $secret
method: POST
url: auth/login
validate:
... ...
name: 企业平台账号登录
base_url: ${ENV(base_business_url)}
base_url: ${ENV(base_business_admin)}
verify: False
variables:
# username: ${ENV(wpftwphone)}
phone: ${ENV(adminphone)}
password: 7c4a8d09ca3762af61e59520943dc26494f8941b
teardown_hooks:
- ${teardown_hook_get_Authorization($response)}
request:
headers:
... ... @@ -16,9 +14,11 @@ request:
X-Requested-With: XMLHttpRequest
json:
password: $password
username: $username
username: ${phone}
method: POST
url: auth/pwdLogin
url: /auth/pwdLogin
extract:
pwdLogintoken: content.data.access.token
validate:
- eq:
- content.msg
... ...
name: 保存抢单任务
base_url: ${ENV(base_worth_url)}
name: 新增抢单任务
base_url: ${ENV(base_manager_url)}
verify: False
variables:
name: 测试抢单任务名称${get_nowtime()}
acceptanceCriteria: 测试抢单任务的验收标准${get_nowtime()}
description: 测试抢单任务的任务描述${get_nowtime()}
isImportant: false
msg: ok
teardown_hooks:
- ${teardown_hook_get_loot_task_id($response)}
#teardown_hooks:
# - ${teardown_hook_get_loot_task_id($response)}
request:
headers:
Content-Type: application/json; charset=UTF-8
Authorization: Bearer ${get_task_Authorization()}
Origin: https://value-test.fjmaimaimai.com
Referer: https://value-test.fjmaimaimai.com/
Authorization: Bearer ${get_task_manager_accesstoken()}
User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.88 Safari/537.36
X-Requested-With: XMLHttpRequest
json:
name: $name
resourceType: 1
resourceList:
- id: ${get_resource_id()}
title: ${get_resource_title()}
content: ${get_resource_content()}
serial: ${get_serialNo()}
# resourceType: 1
# resourceList:
# - id: ${get_resource_id()}
# title: ${get_resource_title()}
# content: ${get_resource_content()}
# serial: ${get_serialNo()}
customerValue:
- 31
taskCharacter: 12
reward: 2000
acceptanceCriteria: $acceptanceCriteria
description: $description
isImportant: true
isImportant: $isImportant
taskBelong: 13
# pictures:
method: POST
url: task/loot/update
url: /task/loot/update
validate:
- eq:
- content.code
- 0
- eq:
- content.msg
- $msg
\ No newline at end of file
... ...
426iJfhpTdwa4y5kRwFiekPznxmETSTA
\ No newline at end of file
eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC9zdXBsdXMtYnVzaW5lc3MtYWRtaW4tZ2F0ZXdheS10ZXN0LmZqbWFpbWFpbWFpLmNvbVwvYXV0aFwvYW5vbnltb3VzTG9naW4iLCJpYXQiOjE1OTk3MjMyNzcsImV4cCI6MTU5OTczNDA3NywibmJmIjoxNTk5NzIzMjc3LCJqdGkiOiJJTmJjQXZlelc5MFhBbnlIIiwic3ViIjozMjQ4ODE3NjEzNjgxNjY0LCJwcnYiOiI4N2UwYWYxZWY5ZmQxNTgxMmZkZWM5NzE1M2ExNGUwYjA0NzU0NmFhIiwiY29tcGFueUlkIjozNjYsIm5pY2tuYW1lIjoiXHU4Yzc5XHU1YjUwXHU1OTM0IiwicGhvbmUiOiIxOTk5MDAwMDAwOCIsImlkIjozMjQ4ODE3NjEzNjgxNjY0LCJhZG1pblR5cGUiOjF9.3VNOCzT9Pu_RGsCICXEsMuM_mFRETunNtoSB_TPDshE
\ No newline at end of file
zbsys7ypbqn
\ No newline at end of file
366
\ No newline at end of file
dd1ea685842935996b653a7535369e29b68d929fa63dad46d1c0bee989c568eba721eb29
\ No newline at end of file
3679205383782400
\ No newline at end of file
3248817613892608
\ No newline at end of file
eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC9zdXBsdXMtd29ydGgtd2ViLWdhdGV3YXktdGVzdC5mam1haW1haW1haS5jb21cL2F1dGhcL2xvZ2luIiwiaWF0IjoxNTk5NzIzMjc3LCJleHAiOjE1OTk3MzQwNzcsIm5iZiI6MTU5OTcyMzI3NywianRpIjoiUUx4dlFBWWlJUzFUNDEyUiIsInN1YiI6MzI0ODgxNzYxMzY4MTY2NCwicHJ2IjoiODdlMGFmMWVmOWZkMTU4MTJmZGVjOTcxNTNhMTRlMGIwNDc1NDZhYSIsImNvbXBhbnlJZCI6MzY2LCJuaWNrbmFtZSI6Ilx1OGM3OVx1NWI1MFx1NTkzNCIsInBob25lIjoiMTk5OTAwMDAwMDgiLCJ1aWQiOjMyNDg4MTc2MTM2ODE2NjQsImFkbWluVHlwZSI6Mn0.C6WiMH4f3HTpNMd90OIPwH0Xj0IO9KQTw_8fFQArMkA
\ No newline at end of file
AdPr5t7P7iGyWEkawhEHjE676QGXHFD2
\ No newline at end of file
rCGkdEk6mjkyz7jkwjezjxsZ5Z5ASjAd
\ No newline at end of file
... ...
v7dgpn5mvm
\ No newline at end of file
3248817613892608
\ No newline at end of file
3248817613863936
\ No newline at end of file
3247366011913216
\ No newline at end of file
3248817613835264
\ No newline at end of file
import json
import time
from urllib import parse
from helpfunc.db_func import *
from helpfunc.header_func import *
from helpfunc.login_func import *
from helpfunc.m_func import *
from helpfunc.pg_db_loot_func import *
from helpfunc.pg_db_bid_func import *
from helpfunc.pg_db_appoint_func import *
# from helpfunc.time_func import *
import time,datetime,re
... ... @@ -23,36 +24,38 @@ def convert_to_string(value):
def convert_to_number(value):
return int(value)
# print(type(convert_to_number(get_resource_id())))
# def get_base_url(env_type="test"):
# """
# 根据配置选择运行环境
# :param env_type:
# :return:
# """
# if env_type == "test":
# return "https://ability-test.fjmaimaimai.com"
# else:
# return "https://ability-prod.fjmaimaimai.com"
def get_nowtime():
return time.strftime("%Y%m%d%H%M%S",time.localtime(time.time()))
def get_second():
curr_time = datetime.datetime.now()
return curr_time.second
def get_starttime():
now = datetime.datetime.now()
start_time = now - datetime.timedelta(hours=now.hour, minutes=now.minute, seconds=now.second, microseconds=now.microsecond)
start_time = str(start_time)
start_time = int(time.mktime(time.strptime(start_time, "%Y-%m-%d %H:%M:%S")))*1000
return start_time
def get_tomorrow():
td = datetime.timedelta(days=1)
tomorrow = (datetime.datetime.utcnow() + td).strftime("%Y-%m-%dT%H:%M:%SZ")
return tomorrow
def get_today1():
td = datetime.timedelta(days=0)
tomorrow = (datetime.datetime.utcnow() + td).strftime("%Y-%m-%dT%H:%M:%SZ")
return tomorrow
def get_endtime():
now = datetime.datetime.now()
start_time = now - datetime.timedelta(hours=now.hour, minutes=now.minute, seconds=now.second,
microseconds=now.microsecond)
end_time = start_time + datetime.timedelta(hours=23, minutes=59, seconds=59)
end_time = str(end_time)
end_time = int(time.mktime(time.strptime(end_time, "%Y-%m-%d %H:%M:%S")))*1000
return end_time
def add(x, y):
return str(int(x)+y)
return int(int(x)+y)
#获取secret用于子系统单点登录
def get_secret(url):
urllist = url.split('code=',1)
code = urllist[1]
de_code = parse.unquote(code)
return de_code
... ...
... ... @@ -3,10 +3,10 @@
# Date: 2020/4/9 11:36
# @Author:bxh
# @file: login_func.py
import json
import time,datetime
path = 'E:/task_api/'
# path = 'E:/mmm_auto/task_api/'
import json
import time, datetime
def teardown_hook_sleep_N_secs(response,n_secs):
""" sleep n seconds after request """
if response.status_code == 200:
... ... @@ -14,20 +14,6 @@ def teardown_hook_sleep_N_secs(response,n_secs):
else:
time.sleep(n_secs)
def teardown_hook_get_cuid(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
cuid =str(jsondata['data']['cuid'])
try:
with open(path + 'config/cuid.csv','w+') as f:
f.write(cuid)
print('写入成功,cuid:{}'.format(cuid))
f.close()
except Exception as e:
print('写入失败', e)
return cuid
def teardown_hook_get_serialNo(response):
if response.status_code == 200:
... ... @@ -36,7 +22,7 @@ def teardown_hook_get_serialNo(response):
try:
with open(path + 'config/serialNo.txt','w+') as f:
with open('config/serialNo.txt','w+') as f:
f.write(serialno)
print('写入成功,serialno:{}'.format(serialno))
f.close()
... ... @@ -44,19 +30,6 @@ def teardown_hook_get_serialNo(response):
print('写入失败', e)
return serialno
def teardown_hook_get_accesstoken(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
access_token =jsondata['data']['accessToken']
try:
# 保存token到文件
with open(path + 'config/accessToken.csv','w+') as f:
f.write(access_token)
print('写入成功,access_token:{}'.format(access_token))
f.close()
except Exception as e:
print('写入失败', e)
return access_token
def teardown_hook_get_task_accesstoken(response):
if response.status_code == 200:
... ... @@ -64,7 +37,7 @@ def teardown_hook_get_task_accesstoken(response):
access_token =jsondata['data']['accessToken']
try:
# 保存token到文件
with open(path + 'config/task_accessToken.csv','w+') as f:
with open('config/task_accessToken.csv','w+') as f:
f.write(access_token)
print('写入成功,access_token:{}'.format(access_token))
f.close()
... ... @@ -72,67 +45,11 @@ def teardown_hook_get_task_accesstoken(response):
print('写入失败', e)
return access_token
def teardown_hook_get_authcode(response):
if response.status_code ==200:
jsondata = json.loads(response.text)
auth_code = jsondata['data']['authCode']
try:
with open(path + "config/authCode.csv", 'w+') as f:
f.write(auth_code)
print('写入成功,authCode:{}'.format(auth_code))
except Exception as e:
print('写入失败', e)
return auth_code
def teardown_hook_get_task_authcode(response):
if response.status_code ==200:
jsondata = json.loads(response.text)
auth_code = jsondata['data']['authCode']
try:
with open(path + "config/task_authCode.csv", 'w+') as f:
f.write(auth_code)
print('写入成功,authCode:{}'.format(auth_code))
except Exception as e:
print('写入失败', e)
return auth_code
def get_authcode():
try:
with open(path + "config/authCode.csv", 'r') as f:
auth_code = f.read()
print('读取成功,authCode:{}'.format(auth_code))
except Exception as e:
print('读取失败', e)
auth_code = str(auth_code)
return auth_code
def get_task_authcode():
try:
with open(path + "config/task_authCode.csv", 'r') as f:
auth_code = f.read()
print('读取成功,authCode:{}'.format(auth_code))
except Exception as e:
print('读取失败', e)
auth_code = str(auth_code)
return auth_code
def get_accesstoken():
try:
# 保存token到文件
with open(path + "config/accessToken.csv", 'r') as f:
accesstoken = f.read()
print('读取成功,accesstoken:{}'.format(accesstoken))
except Exception as e:
print('读取失败', e)
accesstoken = str(accesstoken)
return accesstoken
def get_task_accesstoken():
try:
# 保存token到文件
with open(path + "config/task_accessToken.csv", 'r') as f:
with open("config/task_accessToken.csv", 'r') as f:
accesstoken = f.read()
print('读取成功,accesstoken:{}'.format(accesstoken))
except Exception as e:
... ... @@ -140,124 +57,71 @@ def get_task_accesstoken():
accesstoken = str(accesstoken)
return accesstoken
def get_serialNo():
try:
with open(path + "config/serialNo.txt", 'r') as f:
serialno = f.read()
print('读取成功,serialno:{}'.format(serialno))
except Exception as e:
print('读取失败', e)
serialno = str(serialno)
return serialno
def get_cuid():
global cuid
cuid = ''
try:
with open(path + "config/cuid.csv", 'r') as f:
cuid = f.read()
print('读取成功,cuid:{}'.format(cuid))
except Exception as e:
print('读取失败', e)
cuid = str(cuid)
return cuid
def get_credentials():
global credentials
credentials = ''
def teardown_hook_get_task_manager_accesstoken(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
access_token =jsondata['data']['access']['accessToken']
try:
with open(path + "config/credentials.csv", 'r') as f:
credentials = f.read()
print('读取成功,credentials:{}'.format(credentials))
# 保存token到文件
with open('config/task_manager_accessToken.csv','w+') as f:
f.write(access_token)
print('写入成功,access_token:{}'.format(access_token))
f.close()
except Exception as e:
print('读取失败', e)
# credentials = str(credentials)
return credentials
print('写入失败', e)
return access_token
def get_muid():
global muid
muid = ''
try:
with open(path + "config/muid.csv", 'r') as f:
muid = f.read()
print('读取成功,muid:{}'.format(muid))
except Exception as e:
print('读取失败', e)
muid = str(muid)
return muid
def get_cid():
global cid
cid = ''
def get_task_manager_accesstoken():
try:
with open(path + "config/cid.csv", 'r') as f:
cid = f.read()
print('读取成功,muid:{}'.format(cid))
# 保存token到文件
with open("config/task_manager_accessToken.csv", 'r') as f:
accesstoken = f.read()
print('读取成功,accesstoken:{}'.format(accesstoken))
except Exception as e:
print('读取失败', e)
cid = str(cid)
return cid
t =datetime.datetime.now()
def get_bidStartTime():
#当前日期
t1 = t.strftime('%Y-%m-%d 00:00:00')
# #转为秒级时间戳
# bidStartTime = time.mktime(time.strptime(t1, '%Y-%m-%d %H:%M:%S'))
# #转为毫秒级
# bidStartTime = str(bidStartTime*1000).split(".")[0]
return t1
def get_bidEndTime():
# 1天后
bidEndTime = (t + datetime.timedelta(days=1)).strftime("%Y-%m-%d 00:00:00")
accesstoken = str(accesstoken)
return accesstoken
return bidEndTime
def teardown_hook_get_credentials(response):
def teardown_hook_get_authcode(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
credentials =str(jsondata['data']['credentials'])
auth_code = jsondata['data']['authCode']
try:
with open(path + 'config/credentials.csv','w+') as f:
f.write(credentials)
print('写入成功,credentials:{}'.format(credentials))
# 保存token到文件
with open('config/authCode.csv','w') as f:
f.write(auth_code)
print('写入成功,authCode:{}'.format(auth_code))
f.close()
except Exception as e:
print('写入失败', e)
return credentials
return auth_code
def teardown_hook_get_muid(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
muid =str(jsondata['data']['companys'][0]['muid'])
def get_authcode():
try:
with open(path + 'config/muid.csv','w+') as f:
f.write(muid)
print('写入成功,muid:{}'.format(muid))
with open('config/authCode.csv','r') as f:
authcode_value = f.read()
print('读取authcode_value成功:{}'.format(authcode_value))
f.close()
except Exception as e:
print('写入失败', e)
return muid
print('读取失败', e)
authcode_value = str(authcode_value)
return authcode_value
def teardown_hook_get_cid(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
cid =str(jsondata['data']['companys'][0]['cid'])
def get_serialNo():
try:
with open(path + 'config/cid.csv','w+') as f:
f.write(cid)
print('写入成功,muid:{}'.format(cid))
f.close()
with open("config/serialNo.txt", 'r') as f:
serialno = f.read()
print('读取成功,serialno:{}'.format(serialno))
except Exception as e:
print('写入失败', e)
return cid
print('读取失败', e)
serialno = str(serialno)
return serialno
#————————————————————————————————————————————————————————————————————————————————————————————————————————————
#引用资源模块
def teardown_hook_get_resource_id(response):
... ... @@ -267,7 +131,7 @@ def teardown_hook_get_resource_id(response):
jsondata = json.loads(response.text)
resource_id = str(jsondata['data']['list'][0]['id'])
try:
with open(path + "config/resource_id.txt", 'w+') as f:
with open("config/resource_id.txt", 'w+') as f:
f.write(resource_id)
print('写入成功,resource_id:{}'.format(resource_id))
except Exception as e:
... ... @@ -278,7 +142,7 @@ def get_resource_id():
global resource_id
resource_id =''
try:
with open(path + "config/resource_id.txt", 'r') as f:
with open("config/resource_id.txt", 'r') as f:
resource_id = f.read()
print('读取成功,resource_id:{}'.format(resource_id))
except Exception as e:
... ... @@ -297,7 +161,7 @@ def teardown_hook_get_resource_title(response):
resource_title = jsondata['data']['list'][0]['title']
try:
with open(path + "config/resource_title.txt", 'w+') as f:
with open("config/resource_title.txt", 'w+') as f:
f.write(resource_title)
print('写入成功,resource_title:{}'.format(resource_title))
except Exception as e:
... ... @@ -308,7 +172,7 @@ def get_resource_title():
global resource_title
resource_title = ''
try:
with open(path + "config/resource_title.txt", 'r') as f:
with open("config/resource_title.txt", 'r') as f:
resource_title = f.read()
print('读取成功,resource_id:{}'.format(resource_title))
except Exception as e:
... ... @@ -324,7 +188,7 @@ def teardown_hook_get_resource_content(response):
resource_content = jsondata['data']['list'][0]['content']
try:
with open(path + "config/resource_content.txt", 'w+') as f:
with open("config/resource_content.txt", 'w+') as f:
f.write(resource_content)
print('写入成功,authCode:{}'.format(resource_content))
except Exception as e:
... ... @@ -335,7 +199,7 @@ def get_resource_content():
global resource_content
resource_content = ''
try:
with open(path + "config/resource_content.txt", 'r') as f:
with open("config/resource_content.txt", 'r') as f:
resource_content = f.read()
print('读取成功,resource_content:{}'.format(resource_content))
except Exception as e:
... ...
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# Date: 2020/5/28 23:13
# @Author:bxh
# @file: usiness_admin_func.py
import json
from urllib.parse import *
path = 'E:/task_api/'
# path = 'E:/mmm_auto/task_api/'
def teardown_hook_get_Authorization(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
Authorization =jsondata['data']['access']['token']
try:
# 保存token到文件
with open(path + 'config/Authorization.txt','w+') as f:
f.write(Authorization)
print('写入成功,Authorization:{}'.format(Authorization))
f.close()
except Exception as e:
print('写入失败', e)
return Authorization
def teardown_hook_get_task_Authorization(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
Authorization =jsondata['data']['access']['accessToken']
try:
# 保存token到文件
with open(path + 'config/task_Authorization.txt','w+') as f:
f.write(Authorization)
print('写入成功,Authorization:{}'.format(Authorization))
f.close()
except Exception as e:
print('写入失败', e)
return Authorization
def teardown_hook_get_access_token(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
access_token =jsondata['data']['access']['token']
try:
# 保存token到文件
with open(path + 'config/access_token.txt','w+') as f:
f.write(access_token)
print('写入成功,access_token:{}'.format(access_token))
f.close()
except Exception as e:
print('写入失败', e)
return access_token
def teardown_hook_get_login_code(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
login_code =jsondata['data']['list'][2]['url']
res = login_code.split("=")[1].rstrip('"')
res = unquote(res)
try:
# 保存token到文件
with open(path + 'config/login_code.txt','w+') as f:
f.write(res)
print('写入成功,res:{}'.format(res))
f.close()
except Exception as e:
print('写入失败', e)
return res
#写入抢单任务id
def teardown_hook_get_loot_task_id(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
task_id =jsondata['data']['id']
try:
# 保存token到文件
with open(path + 'config/loot_task_id.txt','w+') as f:
f.write(task_id)
print('写入成功,task_id:{}'.format(task_id))
f.close()
except Exception as e:
print('写入失败', e)
return task_id
#获取抢单任务id
def get_loot_task_id():
try:
# 保存token到文件
with open(path + "config/loot_task_id.txt", 'r') as f:
task_id = f.read()
print('读取成功,task_id:{}'.format(task_id))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return task_id
#写入竞标任务id
def teardown_hook_get_bid_task_id(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
task_id =jsondata['data']['id']
try:
# 保存token到文件
with open(path + 'config/bid_task_id.txt','w+') as f:
f.write(task_id)
print('写入成功,task_id:{}'.format(task_id))
f.close()
except Exception as e:
print('写入失败', e)
return task_id
#获取竞标任务id
def get_bid_task_id():
try:
# 保存token到文件
with open(path + "config/bid_task_id.txt", 'r') as f:
task_id = f.read()
print('读取成功,task_id:{}'.format(task_id))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return task_id
#写入指派任务id
def teardown_hook_get_appoint_task_id(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
task_id =jsondata['data']['id']
try:
# 保存token到文件
with open(path + 'config/appoint_task_id.txt','w+') as f:
f.write(task_id)
print('写入成功,task_id:{}'.format(task_id))
f.close()
except Exception as e:
print('写入失败', e)
return task_id
#第一次写入进行中的数据
def teardown_hook_get_task_3_1_total(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
task_total =str(len(jsondata['data']['tasks']))
try:
with open(path + 'config/task_3_total.txt','w+') as f:
f.write(task_total)
print('写入成功,task_total:{}'.format(task_total))
f.close()
except Exception as e:
print('写入失败', e)
return task_total
#第二次写入进行中的数据
def teardown_hook_get_task_3_2_total(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
task_total =str(len(jsondata['data']['tasks']))
try:
with open(path + 'config/task_3_2_total.txt','w+') as f:
f.write(task_total)
print('写入成功,task_total:{}'.format(task_total))
f.close()
except Exception as e:
print('写入失败', e)
return task_total
#第一次获取进行中的数据
def get_task_3_total():
try:
# 保存token到文件
with open(path + "config/task_3_total.txt", 'r') as f:
task_total = f.read()
print('读取成功,task_total:{}'.format(task_total))
except Exception as e:
print('读取失败', e)
return task_total
#第二次获取进行中的数据
def get_task_3_2_total():
try:
# 保存token到文件
with open(path + "config/task_3_2_total.txt", 'r') as f:
task_total = f.read()
print('读取成功,task_total:{}'.format(task_total))
except Exception as e:
print('读取失败', e)
return task_total
#获取指派任务id
def get_appoint_task_id():
try:
# 保存token到文件
with open(path + "config/appoint_task_id.txt", 'r') as f:
task_id = f.read()
print('读取成功,task_id:{}'.format(task_id))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return task_id
def get_Authorization():
try:
# 保存token到文件
with open(path + "config/Authorization.txt", 'r') as f:
Authorization = f.read()
print('读取成功,Authorization:{}'.format(Authorization))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return Authorization
def get_task_Authorization():
try:
# 保存token到文件
with open(path + "config/task_Authorization.txt", 'r') as f:
Authorization = f.read()
print('读取成功,Authorization:{}'.format(Authorization))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return Authorization
def get_access_token():
try:
# 保存token到文件
with open(path + "config/access_token.txt", 'r') as f:
access_token = f.read()
print('读取成功,access_token:{}'.format(access_token))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return access_token
def get_login_code():
try:
# 保存token到文件
with open(path + "config/login_code.txt", 'r') as f:
login_code = f.read()
print('读取成功,access_token:{}'.format(login_code))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return login_code
#----------------------------获取公共用户id-------------------------
def teardown_hook_get_uid0(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
uid0 =jsondata['data']['list'][0]['uid']
try:
# 保存token到文件
with open(path + 'config/uid0.txt','w+') as f:
f.write(uid0)
print('写入成功,uid0:{}'.format(uid0))
f.close()
except Exception as e:
print('写入失败', e)
return uid0
def get_uid0():
try:
# 保存token到文件
with open(path + "config/uid0.txt", 'r') as f:
uid0 = f.read()
print('读取成功,uid0:{}'.format(uid0))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return uid0
def teardown_hook_get_uid1(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
uid1 =jsondata['data']['list'][1]['uid']
try:
# 保存token到文件
with open(path + 'config/uid1.txt','w+') as f:
f.write(uid1)
print('写入成功,uid1:{}'.format(uid1))
f.close()
except Exception as e:
print('写入失败', e)
return uid1
def get_uid1():
try:
# 保存token到文件
with open(path + "config/uid1.txt", 'r') as f:
uid1 = f.read()
print('读取成功,uid1:{}'.format(uid1))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return uid1
def teardown_hook_get_uid2(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
uid2 = jsondata['data']['list'][2]['uid']
try:
# 保存token到文件
with open(path + 'config/uid2.txt','w+') as f:
f.write(uid2)
print('写入成功,uid2:{}'.format(uid2))
f.close()
except Exception as e:
print('写入失败', e)
return uid2
def get_uid2():
try:
# 保存token到文件
with open(path + "config/uid2.txt", 'r') as f:
uid2 = f.read()
print('读取成功,uid2:{}'.format(uid2))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return uid2
def teardown_hook_get_uid15(response):
if response.status_code == 200:
jsondata = json.loads(response.text)
uid15 =jsondata['data']['list'][15]['uid']
try:
# 保存token到文件
with open(path + 'config/uid15.txt','w+') as f:
f.write(uid15)
print('写入成功,uid15:{}'.format(uid15))
f.close()
except Exception as e:
print('写入失败', e)
return uid15
def get_uid15():
try:
# 保存token到文件
with open(path + "config/uid15.txt", 'r') as f:
uid15 = f.read()
uid15 = int(uid15)
print('读取成功,uid15:{}'.format(uid15))
except Exception as e:
print('读取失败', e)
# Authorization = str(Authorization)
return uid15
\ No newline at end of file
... ... @@ -3,7 +3,6 @@
# Date: 2020/7/12 16:27
# @Author:bxh
# @file: pg_db_func.py
from helpfunc.m_func import *
import psycopg2
from datetime import *
... ...
... ... @@ -3,7 +3,6 @@
# Date: 2020/7/12 16:27
# @Author:bxh
# @file: pg_db_func.py
from helpfunc.m_func import *
import psycopg2
from datetime import *
... ...
... ... @@ -3,7 +3,7 @@
# Date: 2020/7/12 16:27
# @Author:bxh
# @file: pg_db_func.py
from helpfunc.m_func import *
import psycopg2
from datetime import *
... ...
# -*- coding:utf-8 -*-
# @Time :2019/12/4 9:37
# @Author :dengyuting
# @File :sendmsg.py
import os
import json
import requests
JENKINS_URL = str(os.getenv("JENKINS_URL"))
BUILD_NUMBER = str(os.getenv("BUILD_NUMBER"))
JOB_NAME = str(os.getenv("JOB_NAME"))
CAUSE = str(os.getenv("CAUSE"))
BUILD_URL = str(os.getenv("BUILD_URL"))
JOB_URL = str(os.getenv("JOB_URL"))
path = os.path.dirname(__file__)
summary_file = os.path.join(path, 'logs','testsuites','task_testsuites.summary.json')
def getresult():
try:
with open(summary_file, 'r', encoding='UTF-8') as f:
f = f.read()
jsonfile = json.loads(f)
if jsonfile["success"] == True:
result = "SUCCESS"
else:
result = "FAIL"
total = jsonfile["stat"]["testcases"]["total"]
success = jsonfile["stat"]["testcases"]["success"]
fail = jsonfile["stat"]["testcases"]["fail"]
duration = round(jsonfile["time"]["duration"])
# teststeps_total = jsonfile["stat"]["teststeps"]["total"]
# teststeps_successes = jsonfile["stat"]["teststeps"]["successes"]
# teststeps_failures = jsonfile["stat"]["teststeps"]["failures"]
# teststeps_errors = jsonfile["stat"]["teststeps"]["errors"]
# teststeps_skipped = jsonfile["stat"]["teststeps"]["skipped"]
return result, total, success, fail, duration
except Exception as err:
print("this is err:{}" .format(err))
def sendinfo():
r =getresult()
data = {}
data['msgtype'] = 'text'
data['text'] = {}
data['text']['content'] = '价值系统项目【mmm_value_api_test】:' \
'\n测试结果:'+r[0]+ \
'\n执行时间:' +str(r[4])+ \
's\n共执行测试用例:' +str(r[1]) +'\nSUCCESS:' +str(r[2])+ '\nFAIL:' +str(r[3])+ \
'\n测试报告地址:http://jenkins.fjmaimaimai.com/view/test/job/mmm_value_api_test/HTML_20Report/'
# data['text']['mentioned_mobile_list'] = ["13559112969","@all"]
# data['text']['content'] = '【opp_api】测试执行结果:' + r[0] + \
# '\n 执行时间:' + str(r[4]) + \
# 's\n TOTAL:' + str(r[1]) + '\n SUCCESS:' + str(r[2]) + '\n FAIL:' + str(r[3])
url = 'https://oapi.dingtalk.com/robot/send?access_token=9a52a7e69fd1bd7cb01e86bf0577af4d74dc15a50f1b17234c50ec2df856021e'
headers = {'Content-Type': 'application/json'}
requests.post(url, json=data, headers=headers)
if __name__ == '__main__':
sendinfo()
... ...
config:
name: ME001-保存抢单任务-任务数量统计待发布+1
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 保存抢单任务
variables:
action: 0
type: 0
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第二次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,1)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME002-保存竞标任务-任务数量统计待发布+1
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 保存竞标任务
variables:
action: 0
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第二次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,1)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME003-保存指派任务-任务数量统计待发布+1
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 保存指派任务
variables:
action: 0
type: 2
plannedFinishDate: ${get_endtime()}
uid: 3284714710070272
uname: '价值系统账号1'
title: '指派任务标题${get_nowtime()}'
content: '指派任务内容${get_nowtime()}'
acceptability: '指派任务验收标准${get_nowtime()}'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第二次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,1)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME004-发布抢单任务-任务数量统计待领取+1
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 发布抢单任务
variables:
action: 1
type: 0
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第二次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,1)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME005-发布竞标任务-任务数量统计待领取+1
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第二次查看我发布的-待发布
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,1)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME006-发布指派任务-任务数量统计进行中+1
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 发布指派任务
variables:
action: 1
type: 2
plannedFinishDate: ${get_endtime()}
uid: 3284714710070272
uname: '价值系统账号1'
title: '指派任务标题${get_nowtime()}'
content: '指派任务内容${get_nowtime()}'
acceptability: '指派任务验收标准${get_nowtime()}'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,1)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME007-抢单任务被领取-任务数量统计待领取-1,待确认+1
base_url: ${ENV(base_url)}
variables:
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布抢单任务
variables:
action: 1
api: api/app_api/task_api/taskPublish_api.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看抢单任务列表
variables:
action: 0
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取任务
variables:
action: 0
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,-1)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,1)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME008-竞标任务被领取-任务数量统计不变,还是待领取状态
base_url: ${ENV(base_url)}
variables:
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看竞标任务列表
variables:
action: 1
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取竞标任务
variables:
action: 1
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME009-抢单任务被确认-任务数量统计待确认-1,进行中+1
base_url: ${ENV(base_url)}
variables:
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布抢单任务
variables:
action: 1
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看抢单任务列表
variables:
action: 0
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取任务
variables:
action: 0
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 查看我发布的-待确认
variables:
action: 5
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 确认领取人
variables:
taskId: $tasks_id
planDate: ${get_endtime()}
api: api/app_api/task_api/verifyReceiver_api.yml
validate:
- eq:
- content.msg
- 确认成功
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,-1)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,1)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME010-竞标人确认-任务数量统计待领取-1,进行中+1
base_url: ${ENV(base_url)}
variables:
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看竞标任务列表
variables:
action: 1
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取竞标任务
variables:
action: 1
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 查看我发布的-待领取
variables:
action: 1
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 查看任务详情
variables:
id: $tasks_id
api: api/app_api/task_api/taskDetails_api.yml
extract:
- bidders: content.data.task.bidders.0.uid
validate:
- eq:
- content.msg
- 获取详情成功
- eq:
- content.data.task.title
- $title
- name: 竞标人中标确认
variables:
id: $tasks_id
uid: $bidders
planFinishDate: ${get_endtime()}
api: api/app_api/task_api/bidTask_api.yml
validate:
- eq:
- content.msg
- 中标成功
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,-1)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,1)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME011-抢单任务已完成待验收-任务数量统计进行中-1,待验收+1
base_url: ${ENV(base_url)}
variables:
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布抢单任务
variables:
action: 1
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看抢单任务列表
variables:
action: 0
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取任务
variables:
action: 0
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待确认
variables:
action: 5
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 确认领取人
variables:
taskId: $tasks_id
planDate: ${get_endtime()}
api: api/app_api/task_api/verifyReceiver_api.yml
validate:
- eq:
- content.msg
- 确认成功
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,-1)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,1)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME012-竞标人完成任务-任务数量统计进行中-1,待验收+1
base_url: ${ENV(base_url)}
variables:
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看竞标任务列表
variables:
action: 1
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取竞标任务
variables:
action: 1
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待领取
variables:
action: 1
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 查看任务详情
variables:
id: $tasks_id
api: api/app_api/task_api/taskDetails_api.yml
extract:
- bidders: content.data.task.bidders.0.uid
validate:
- eq:
- content.msg
- 获取详情成功
- eq:
- content.data.task.title
- $title
- name: 竞标人中标确认
variables:
id: $tasks_id
uid: $bidders
planFinishDate: ${get_endtime()}
api: api/app_api/task_api/bidTask_api.yml
validate:
- eq:
- content.msg
- 中标成功
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,-1)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,1)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME013-发布指派任务-任务数量统计进行中-1,待验收+1
base_url: ${ENV(base_url)}
variables:
title: '指派任务标题${get_nowtime()}'
content: '指派任务内容${get_nowtime()}'
acceptability: '指派任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布指派任务
variables:
action: 1
type: 2
plannedFinishDate: ${get_endtime()}
uid: 3284714710070272
uname: '价值系统账号1'
api: api/app_api/task_api/taskPublish_api.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看指派我的-进行中
variables:
action: 0
api: api/app_api/task_api/AssignMeTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,-1)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,1)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME014-抢单任务验收成功-任务数量统计待验收-1,完成+1
base_url: ${ENV(base_url)}
variables:
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布抢单任务
variables:
action: 1
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看抢单任务列表
variables:
action: 0
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取任务
variables:
action: 0
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待确认
variables:
action: 5
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 确认领取人
variables:
taskId: $tasks_id
planDate: ${get_endtime()}
api: api/app_api/task_api/verifyReceiver_api.yml
validate:
- eq:
- content.msg
- 确认成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 验收任务
variables:
id: $tasks_id
actualFinishDate: ${get_endtime()}
api: api/app_api/task_api/checkAccept_api.yml
validate:
- eq:
- content.msg
- 验收成功
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,-1)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,1)}
\ No newline at end of file
... ...
config:
name: ME015-竞标任务验收成功-任务数量统计待验收-1,完成+1
base_url: ${ENV(base_url)}
variables:
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看竞标任务列表
variables:
action: 1
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取竞标任务
variables:
action: 1
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待领取
variables:
action: 1
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 查看任务详情
variables:
id: $tasks_id
api: api/app_api/task_api/taskDetails_api.yml
extract:
- bidders: content.data.task.bidders.0.uid
validate:
- eq:
- content.msg
- 获取详情成功
- eq:
- content.data.task.title
- $title
- name: 竞标人中标确认
variables:
id: $tasks_id
uid: $bidders
planFinishDate: ${get_endtime()}
api: api/app_api/task_api/bidTask_api.yml
validate:
- eq:
- content.msg
- 中标成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 验收任务
variables:
id: $tasks_id
actualFinishDate: ${get_endtime()}
api: api/app_api/task_api/checkAccept_api.yml
validate:
- eq:
- content.msg
- 验收成功
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,-1)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,1)}
\ No newline at end of file
... ...
config:
name: ME016-指派任务验收完成-任务数量统计待验收-1,已完成+1
base_url: ${ENV(base_url)}
variables:
title: '指派任务标题${get_nowtime()}'
content: '指派任务内容${get_nowtime()}'
acceptability: '指派任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布指派任务
variables:
action: 1
type: 2
plannedFinishDate: ${get_endtime()}
uid: 3284714710070272
uname: '价值系统账号1'
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看指派我的-进行中
variables:
action: 0
api: api/app_api/task_api/AssignMeTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iPublishedWaitPublish: content.data.taskMsg.iPublishedWaitPublish
- iPublishedToReceive: content.data.taskMsg.iPublishedToReceive
- iPublishedWaitVerify: content.data.taskMsg.iPublishedWaitVerify
- iPublishedInProgress: content.data.taskMsg.iPublishedInProgress
- iPublishedWaitAcceptance: content.data.taskMsg.iPublishedWaitAcceptance
- iPublishedCompleted: content.data.taskMsg.iPublishedCompleted
- name: 验收任务
variables:
id: $tasks_id
actualFinishDate: ${get_endtime()}
api: api/app_api/task_api/checkAccept_api.yml
validate:
- eq:
- content.msg
- 验收成功
- name: 第二次查看我发布的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iPublishedWaitPublish
- ${add($iPublishedWaitPublish,0)}
- eq:
- content.data.taskMsg.iPublishedToReceive
- ${add($iPublishedToReceive,0)}
- eq:
- content.data.taskMsg.iPublishedWaitVerify
- ${add($iPublishedWaitVerify,0)}
- eq:
- content.data.taskMsg.iPublishedInProgress
- ${add($iPublishedInProgress,0)}
- eq:
- content.data.taskMsg.iPublishedWaitAcceptance
- ${add($iPublishedWaitAcceptance,-1)}
- eq:
- content.data.taskMsg.iPublishedCompleted
- ${add($iPublishedCompleted,1)}
\ No newline at end of file
... ...
config:
name: ME017-领取抢单任务-我领取的数量正确
base_url: ${ENV(base_url)}
variables:
title: '抢单任务标题${get_nowtime()}'
content: '抢单任务内容${get_nowtime()}'
acceptability: '抢单任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布抢单任务
variables:
action: 1
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我领取的-待确认
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iGetWaitVerify: content.data.taskMsg.iGetWaitVerify
- iGetInProgress: content.data.taskMsg.iGetInProgress
- iGetWaitAcceptance: content.data.taskMsg.iGetWaitAcceptance
- iGetCompleted: content.data.taskMsg.iGetCompleted
- name: 查看抢单任务列表
variables:
action: 0
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取任务
variables:
action: 0
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: 第二次查看我领取的-待确认+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,1)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待确认
variables:
action: 5
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 确认领取人
variables:
taskId: $tasks_id
planDate: ${get_endtime()}
api: api/app_api/task_api/verifyReceiver_api.yml
validate:
- eq:
- content.msg
- 确认成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我领取的-进行中+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,1)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: 查看我领取的-待验收+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,1)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 验收任务
variables:
id: $tasks_id
actualFinishDate: ${get_endtime()}
api: api/app_api/task_api/checkAccept_api.yml
validate:
- eq:
- content.msg
- 验收成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我领取的-已完成+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,1)}
\ No newline at end of file
... ...
config:
name: ME018-领取竞标任务-我领取的、我参与的数量正确
base_url: ${ENV(base_url)}
variables:
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我参与的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iGetWaitVerify: content.data.taskMsg.iGetWaitVerify
- iGetInProgress: content.data.taskMsg.iGetInProgress
- iGetWaitAcceptance: content.data.taskMsg.iGetWaitAcceptance
- iGetCompleted: content.data.taskMsg.iGetCompleted
- iParticipationBid: content.data.taskMsg.iParticipationBid
- iParticipationCompleted: content.data.taskMsg.iParticipationCompleted
- name: 查看竞标任务列表
variables:
action: 1
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取竞标任务
variables:
action: 1
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: 第二次查看我领取的、我参与的-竞标中+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- eq:
- content.data.taskMsg.iParticipationBid
- ${add($iParticipationBid,1)}
- eq:
- content.data.taskMsg.iParticipationCompleted
- ${add($iParticipationCompleted,0)}
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待领取
variables:
action: 1
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 查看任务详情
variables:
id: $tasks_id
api: api/app_api/task_api/taskDetails_api.yml
extract:
- bidders: content.data.task.bidders.0.uid
validate:
- eq:
- content.msg
- 获取详情成功
- eq:
- content.data.task.title
- $title
- name: 竞标人中标确认
variables:
id: $tasks_id
uid: $bidders
planFinishDate: ${get_endtime()}
api: api/app_api/task_api/bidTask_api.yml
validate:
- eq:
- content.msg
- 中标成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我领取的-进行中+1、我参与的-竞标中回到初始状态
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,1)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- eq:
- content.data.taskMsg.iParticipationBid
- ${add($iParticipationBid,0)}
- eq:
- content.data.taskMsg.iParticipationCompleted
- ${add($iParticipationCompleted,0)}
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: 查看我领取的-进行中回到初始状态,待验收+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,1)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- eq:
- content.data.taskMsg.iParticipationBid
- ${add($iParticipationBid,0)}
- eq:
- content.data.taskMsg.iParticipationCompleted
- ${add($iParticipationCompleted,0)}
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 验收任务
variables:
id: $tasks_id
actualFinishDate: ${get_endtime()}
api: api/app_api/task_api/checkAccept_api.yml
validate:
- eq:
- content.msg
- 验收成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我领取的-待验收回到初始状态,已完成+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,1)}
- eq:
- content.data.taskMsg.iParticipationBid
- ${add($iParticipationBid,0)}
- eq:
- content.data.taskMsg.iParticipationCompleted
- ${add($iParticipationCompleted,0)}
\ No newline at end of file
... ...
config:
name: ME019-竞标任务-参与人的“我参与的-已完成”数量校验
base_url: ${ENV(base_url)}
variables:
title: '竞标任务标题${get_nowtime()}'
content: '竞标任务内容${get_nowtime()}'
acceptability: '竞标任务验收标准${get_nowtime()}'
teststeps:
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 发布竞标任务
variables:
action: 1
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看竞标任务列表
variables:
action: 1
newest: 1
api: api/app_api/task_api/contendTasks_api.yml
extract:
- tasks_id: content.data.tasks.0.id
validate:
- eq:
- content.data.tasks.0.title
- $title
- name: 领取竞标任务
variables:
action: 1
id: $tasks_id
api: api/app_api/task_api/submitCompete_api.yml
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我发布的-待领取
variables:
action: 1
api: api/app_api/task_api/iPublishedTasks_api.yml
validate:
- eq:
- content.data.tasks.0.title
- $title
- eq:
- content.data.tasks.0.id
- $tasks_id
- name: 查看任务详情
variables:
id: $tasks_id
api: api/app_api/task_api/taskDetails_api.yml
extract:
- bidders: content.data.task.bidders.0.uid
validate:
- eq:
- content.msg
- 获取详情成功
- eq:
- content.data.task.title
- $title
- name: 竞标人中标确认
variables:
id: $tasks_id
uid: $bidders
planFinishDate: ${get_endtime()}
api: api/app_api/task_api/bidTask_api.yml
validate:
- eq:
- content.msg
- 中标成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone1)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 完成任务
variables:
id: $tasks_id
api: api/app_api/task_api/finishTask_api.yml
validate:
- eq:
- content.msg
- 完成成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone3)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 第一次查看我领取的、我参与的
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
extract:
- iGetWaitVerify: content.data.taskMsg.iGetWaitVerify
- iGetInProgress: content.data.taskMsg.iGetInProgress
- iGetWaitAcceptance: content.data.taskMsg.iGetWaitAcceptance
- iGetCompleted: content.data.taskMsg.iGetCompleted
- iParticipationBid: content.data.taskMsg.iParticipationBid
- iParticipationCompleted: content.data.taskMsg.iParticipationCompleted
- name: $phone 登录系统
variables:
phone: ${ENV(phone2)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 验收任务
variables:
id: $tasks_id
actualFinishDate: ${get_endtime()}
api: api/app_api/task_api/checkAccept_api.yml
validate:
- eq:
- content.msg
- 验收成功
- name: $phone 登录系统
variables:
phone: ${ENV(phone3)}
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看我领取的、我参与的-已完成+1
api: api/app_api/taskStatistics_api/taskStatistics_api.yml
validate:
- eq:
- content.data.taskMsg.iGetWaitVerify
- ${add($iGetWaitVerify,0)}
- eq:
- content.data.taskMsg.iGetInProgress
- ${add($iGetInProgress,0)}
- eq:
- content.data.taskMsg.iGetWaitAcceptance
- ${add($iGetWaitAcceptance,0)}
- eq:
- content.data.taskMsg.iGetCompleted
- ${add($iGetCompleted,0)}
- eq:
- content.data.taskMsg.iParticipationBid
- ${add($iParticipationBid,0)}
- eq:
- content.data.taskMsg.iParticipationCompleted
- ${add($iParticipationCompleted,1)}
\ No newline at end of file
... ...
config:
name: PF001价值系统-拥有发布任务权限登录价值系统
name: PF001价值系统-主管理员拥有发布任务权限
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(adminphone)}
teststeps:
... ... @@ -8,14 +10,11 @@ teststeps:
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 获取用户信息
api: api/app_api/user_api/userInfo_api.yml
variables:
permissionTaskPublish: 1
varidate:
validate:
api: api/app_api/login_api/userinfo_api.yml
validate:
- eq:
- content.data.user.permissionTaskPublish
- $permissionTaskPublish
- 1
- eq:
- content.data.msg
- 获取用户信息
... ...
config:
name: PF002价值系统-无任务管理权限的人员登录系统
name: PF002价值系统-无任务管理权限的人员登录系统,无发布按钮
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone1)}
teststeps:
- name: 价值系统-无任务管理权限的人员登录系统
variables:
phone: ${ENV(wtaskphone)}
testcase: testcases/common/login_testcases.yml
- name: $phone 登陆系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 获取用户信息
api: api/app_api/user_api/userInfo_api.yml
variables:
permissionTaskPublish: 0
varidate:
validate:
api: api/app_api/login_api/userinfo_api.yml
validate:
- eq:
- content.data.user.permissionTaskPublish
- $permissionTaskPublish
- 0
- eq:
- content.data.msg
- 获取用户信息
... ...
config:
name: PF003价值系统-无任务管理权限的人员登录系统,无发布按钮
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(phone2)}
teststeps:
- name: $phone 登陆系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 获取用户信息
api: api/app_api/login_api/userinfo_api.yml
validate:
- eq:
- content.data.user.permissionTaskPublish
- 1
- eq:
- content.data.msg
- 获取用户信息
... ...
config:
name: 用户登录APP
base_url: ${ENV(base_url)}
variables:
phone: ${ENV(adminphone)}
teststeps:
- name: $phone 登陆统一用户中心
api: api/app_api/login_api/ucenter_login_api.yml
extract:
cuid: content.data.cuid
credentials: content.data.credentials
muid: content.data.companys.0.muid
varidate:
validate:
- eq:
- content.msg
- ok
- name: 价值系统登录
api: api/app_api/login_api/task/authorize_api.yml
variables:
credentials: $credentials
cuid: $cuid
muid: $muid
cid: ${ENV(companyid)}
api: api/app_api/login_api/authorize_api.yml
teardown_hooks:
- ${teardown_hook_get_task_authcode($response)}
- ${teardown_hook_get_authcode($response)}
varidate:
validate:
- eq:
- content.msg
- 登录成功accessToken
- 登录成功
- name: 获取accessToken
api: api/app_api/login_api/task/accessToken_api.yml
api: api/app_api/login_api/accessToken_api.yml
teardown_hooks:
- ${teardown_hook_get_task_accesstoken($response)}
varidate:
validate:
validate:
- eq:
- content.msg
- 获取成功
... ...
config:
name: 用户登录管理后台
base_url: ${ENV(base_business_url)}
teststeps:
- name: 登录企业平台
api: api/m_api/login_api/auth/pwdLogin_api.yml
# variables:
# username: ${ENV(wpftwphone)}
teardown_hooks:
- ${teardown_hook_get_Authorization($response)}
api: api/m_api/login_api/pwdLogin_api.yml
extract:
pwdLogintoken: content.data.access.token
varidate:
validate:
- eq:
- content.msg
- ok
- name: 用户的公司列表
output:
- companyId
api: api/m_api/login_api/auth/userCompamies_api.yml
- name: 选择公司登陆
variables:
companyId: ${ENV(companyId)}
api: api/m_api/login_api/anonymousLogin_api.yml
extract:
companyId: content.data.company.0.id
validate:
- eq:
- content.msg
- ok
- eq:
- content.data.company.0.id
- $companyId
- name: 登录公司
api: api/m_api/login_api/auth/anonymousLogin_api.yml
teardown_hooks:
- ${teardown_hook_get_access_token($response)}
anonymousLogintoken: content.data.access.token
varidate:
validate:
- eq:
- content.msg
- ok
#
- name: 登录列表
api: api/m_api/login_api/auth/getSingleLoginMenus_api.yml
teardown_hooks:
- ${teardown_hook_get_login_code($response)}
- name: 单点登录,获取secret用于登录子系统
api: api/m_api/login_api/getSingleLoginMenus_api.yml
extract:
url: content.data.list.0.url
varidate:
validate:
- eq:
- content.msg
- ok
#
- name: 登录价值系统
api: api/m_api/login_api/auth/login_api.yml
api: api/m_api/login_api/login_api.yml
teardown_hooks:
- ${teardown_hook_get_task_Authorization($response)}
varidate:
validate:
- ${teardown_hook_get_task_manager_accesstoken($response)}
validate:
- eq:
- content.msg
- ok
\ No newline at end of file
... ...
config:
name: 用户新增抢单任务
variables:
phone: ${ENV(adminphone)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 新增抢单任务
api: api/app_api/task_api/taskPublish_api.yml
validate:
- eq:
- content.msg
- ok
... ...
config:
name: 用户新增竞标任务
variables:
phone: ${ENV(adminphone)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 新增竞标任务
variables:
action: 0
type: 1
bidStartTime: ${get_starttime()}
bidEndTime: ${get_endtime()}
api: api/app_api/task_api/taskPublish_api.yml
validate:
- eq:
- content.msg
- ok
... ...
config:
name: 用户新增指派任务
variables:
phone: ${ENV(adminphone)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 新增指派任务
variables:
action: 0
type: 2
plannedFinishDate: ${get_endtime()}
uid: 3284714710070272
uname: '价值系统账号1'
api: api/app_api/task_api/taskPublish_api.yml
validate:
- eq:
- content.msg
- ok
... ...
config:
name: 账号登录测试
base_url: ${ENV(base_url)}
teststeps:
- name: 登录统一用户中心
api: api/app_api/login_api/auth/ucenter_login_api.yml
teardown_hooks:
- ${teardown_hook_get_cuid($response)}
- ${teardown_hook_get_credentials($response)}
- ${teardown_hook_get_muid($response)}
- ${teardown_hook_get_cid($response)}
variables:
phone: ${ENV(appphone)}
varidate:
validate:
- eq:
- content.msg
- ok
- name: 登录app系统
api: api/app_api/login_api/auth/authorize_api.yml
teardown_hooks:
- ${teardown_hook_get_authcode($response)}
varidate:
validate:
- eq:
- content.msg
- 登录成功accessToken
- name: 获取accessToken
api: api/app_api/login_api/auth/accessToken_api.yml
teardown_hooks:
- ${teardown_hook_get_accesstoken($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
config:
name: 用户新增抢单任务
variables:
phone: ${ENV(adminphone)}
teststeps:
- name: $phone 登录系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 新增抢单任务
api: api/app_api/task_api/taskPublish_api.yml
varidate:
- eq:
- content.msg
- ok
... ...
config:
name: APP端首页-公司悬赏任务
base_url: ${ENV(base_url)}
teststeps:
- name: 用户新增抢单任务-公司重要悬赏
testcase: testcases/common/COM004_loot_update_testcase.yml
- name: 登录系统
testcase: testcases/common/login_testcases.yml
- name: 登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
- name: 查看公司悬赏任务
api: api/app_api/task_rewards_api.yml
variables:
id: ${get_loot_task_id()}
varidate:
validate:
- eq:
- content.code
- 0
- eq:
- content.data.tasks.0.id
- $id
- eq:
- content.msg
- 获取成功
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-待发布状态不统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
#
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个待发布的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM007_loot_update_status_1_testcase.yml
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total1: ${get_task_3_total()}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-已发布,待领取状态不统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
#
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个已发布,待领取的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM008_loot_open_status_2_testcase.yml
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total1: ${get_task_3_total()}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-进行中状态统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
##
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个进行中的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM010_loot_open_status_3_testcase.yml
##
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total: ${get_task_3_total()}
task_total1: ${add($task_total,1)}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-已完成,待验收状态统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
##
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个已完成,待验收的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM011_loot_open_status_4_testcase.yml
##
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total1: ${get_task_3_total()}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-已完成状态统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
##
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个已完成的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM012_loot_open_status_5_testcase.yml
##
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total1: ${get_task_3_total()}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-已关闭状态统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
##
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个已关闭的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM013_loot_open_status_6_testcase.yml
##
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total1: ${get_task_3_total()}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
config:
name: APP端首页-进行中数量统计-已领取,待确认状态统计
base_url: ${ENV(base_url)}
teststeps:
- name: 第一次登录系统
testcase: testcases/common/login_testcases.yml
- name: 第一次登录价值系统
testcase: testcases/common/COM001_task_login_testcases.yml
##
- name: 第一次查看公司任务(进行中)
api: api/app_api/task_currentTasks_1_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_1_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
#
- name: B用户登录管理后台,新增一个已领取,待确认的任务
variables:
username: ${ENV(appphone1)}
testcase: testcases/common/COM009_loot_open_status_7_testcase.yml
##
- name: 第二次查看公司任务(进行中)
api: api/app_api/task_currentTasks_2_api.yml
teardown_hooks:
- ${teardown_hook_get_task_3_2_total($response)}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- name: 第三次查看公司任务(进行中)
api: api/app_api/task_currentTasks_3_api.yml
variables:
task_total1: ${get_task_3_total()}
task_total2: ${get_task_3_2_total()}
varidate:
validate:
- eq:
- content.msg
- 获取成功
- eq:
- $task_total1
- $task_total2
\ No newline at end of file
... ... @@ -2,4 +2,4 @@ config:
name: start_testcases
#清理数据
teardown_hooks:
- ${setup_hook_clean_db(366)}
\ No newline at end of file
- ${setup_hook_clean_db(214)}
\ No newline at end of file
... ...
config:
name: "测试集demo"
testcases:
- name: start....初始化数据库
testcase: testcases/start_testcases.yml
#
#- name: member_list 成员管理搜索
# testcase: testcases/task/member/member_list_testcases.yml
#
#- name: member_set_permission 成员管理设置权限
# testcase: testcases/task/member/member_set_permission_testcases.yml
#- name: 测试流程
# testcase: testcases/common/COM012_loot_open_status_5_testcase.yml
\ No newline at end of file
config:
name: "测试集demo"
testcases:
#- name: start....初始化数据库
# testcase: testcases/start_testcases.yml
##############################################权限测试用例开始###################################
- name: PF001价值系统-主管理员拥有发布任务权限
testcase: testcases/app/userInfo/PF001-admin.yml
- name: PF002价值系统-无任务管理权限的人员登录系统,无发布按钮
testcase: testcases/app/userInfo/PF002-not-permi.yml
- name: PF003价值系统-无任务管理权限的人员登录系统,无发布按钮
testcase: testcases/app/userInfo/PF003-has-permi.yml
##############################################权限测试用例结束###################################
##############################################个人中心数量统计用例开始###################################
- name: ME001-保存抢单任务-任务数量统计待发布+1
testcase: testcases/app/taskStatistics/ME001-taskStatistics-lootsave.yml
- name: ME002-保存竞标任务-任务数量统计待发布+1
testcase: testcases/app/taskStatistics/ME002-taskStatistics-bidsave.yml
- name: ME003-保存指派任务-任务数量统计待发布+1
testcase: testcases/app/taskStatistics/ME003-taskStatistics-appointsave.yml
- name: ME004-发布抢单任务-任务数量统计待领取+1
testcase: testcases/app/taskStatistics/ME004-taskStatistics-lootpublish.yml
- name: ME005-发布竞标任务-任务数量统计待领取+1
testcase: testcases/app/taskStatistics/ME005-taskStatistics-bidpublish.yml
- name: ME006-发布指派任务-任务数量统计进行中+1
testcase: testcases/app/taskStatistics/ME006-taskStatistics-appointpublish.yml
- name: ME007-抢单任务被领取-任务数量统计待领取-1,待确认+1
testcase: testcases/app/taskStatistics/ME007-taskStatistics-lootreceive.yml
- name: ME008-竞标任务被领取-任务数量统计不变,还是待领取状态
testcase: testcases/app/taskStatistics/ME008-taskStatistics-bidreceive.yml
- name: ME009-抢单任务被确认-任务数量统计待确认-1,进行中+1
testcase: testcases/app/taskStatistics/ME009-taskStatistics-lootVerify.yml
- name: ME010-竞标人确认-任务数量统计待领取-1,进行中+1
testcase: testcases/app/taskStatistics/ME010-taskStatistics-bidVerify.yml
- name: ME011-抢单任务已完成待验收-任务数量统计进行中-1,待验收+1
testcase: testcases/app/taskStatistics/ME011-taskStatistics-lootWaitAcceptance.yml
- name: ME012-竞标人完成任务-任务数量统计进行中-1,待验收+1
testcase: testcases/app/taskStatistics/ME012-taskStatistics-bidWaitAcceptance.yml
- name: ME013-发布指派任务-任务数量统计进行中-1,待验收+1
testcase: testcases/app/taskStatistics/ME013-taskStatistics-appointWaitAcceptance.yml
- name: ME014-抢单任务验收成功-任务数量统计待验收-1,完成+1
testcase: testcases/app/taskStatistics/ME014-taskStatistics-lootCompleted.yml
- name: ME015-竞标任务验收成功-任务数量统计待验收-1,完成+1
testcase: testcases/app/taskStatistics/ME015-taskStatistics-bidCompleted.yml
- name: ME016-指派任务验收完成-任务数量统计待验收-1,已完成+1
testcase: testcases/app/taskStatistics/ME016-taskStatistics-appointCompleted.yml
- name: ME017-领取抢单任务-我领取的数量正确
testcase: testcases/app/taskStatistics/ME017-taskStatistics-iget-loot.yml
- name: ME018-领取竞标任务-我领取的、我参与的数量正确
testcase: testcases/app/taskStatistics/ME018-taskStatistics-iParticipation-bid.yml
- name: ME019-竞标任务-参与人的“我参与的-已完成”数量校验
testcase: testcases/app/taskStatistics/ME019-taskStatistics-iParticipation-bidPart.yml
\ No newline at end of file
... ...