Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oto
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
龚小红
oto
Commits
f2f6b7c8
Commit
f2f6b7c8
authored
May 22, 2023
by
龚小红
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'Feature/checkChart_20230519_gxh' into 'master'
增加经营盘点的测试用例 See merge request
!99
parents
a5d4b6b8
32acaae7
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
41 additions
and
39 deletions
+41
-39
Activity.java
src/test/java/com/oto/cases/otoseller/Activity.java
+20
-20
CheckTask.java
src/test/java/com/oto/cases/otoseller/CheckTask.java
+10
-10
Phone.java
src/test/java/com/oto/cases/otoseller/Phone.java
+1
-1
Work.java
src/test/java/com/oto/cases/otoseller/Work.java
+7
-5
BasicConfig.java
src/test/java/com/oto/config/BasicConfig.java
+3
-3
No files found.
src/test/java/com/oto/cases/otoseller/Activity.java
View file @
f2f6b7c8
...
@@ -156,8 +156,8 @@ public class Activity implements Authorization {
...
@@ -156,8 +156,8 @@ public class Activity implements Authorization {
sleep
(
2000
);
sleep
(
2000
);
updateInvite
(
1
,
now
+
3600000
,
cust_id
+
3
);
updateInvite
(
1
,
now
+
3600000
,
cust_id
+
3
);
oto
Assist
Auth
();
oto
Leader
Auth
();
getCalendarlist
(
today
,
0
,
"自动化测试用户2"
,
"勿动-自动化测试邀约"
);
getCalendarlist
(
today
,
3
,
"自动化测试用户2"
,
"勿动-自动化测试邀约"
);
getCalendarlist
(
today
,
2
,
"自动化测试用户0"
,
"勿动-自动化测试邀约"
);
getCalendarlist
(
today
,
2
,
"自动化测试用户0"
,
"勿动-自动化测试邀约"
);
}
}
...
@@ -260,7 +260,7 @@ public class Activity implements Authorization {
...
@@ -260,7 +260,7 @@ public class Activity implements Authorization {
public
void
专家确认客户到场
(){
public
void
专家确认客户到场
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"date"
,
today
);
params
.
put
(
"date"
,
today
);
params
.
put
(
"custId"
,
IdMakeUtil
.
encodingId
((
long
)
cust_id
-
1
));
params
.
put
(
"custId"
,
IdMakeUtil
.
encodingId
((
long
)
cust_id
+
3
));
params
.
put
(
"configId"
,
440
);
params
.
put
(
"configId"
,
440
);
params
.
put
(
"status"
,
1
);
params
.
put
(
"status"
,
1
);
params
.
put
(
"timeInterval"
,
"am"
);
params
.
put
(
"timeInterval"
,
"am"
);
...
@@ -275,7 +275,7 @@ public class Activity implements Authorization {
...
@@ -275,7 +275,7 @@ public class Activity implements Authorization {
public
void
专家确认客户未到场
(){
public
void
专家确认客户未到场
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"date"
,
today
);
params
.
put
(
"date"
,
today
);
params
.
put
(
"custId"
,
IdMakeUtil
.
encodingId
((
long
)
cust_id
+
3
));
params
.
put
(
"custId"
,
IdMakeUtil
.
encodingId
((
long
)
cust_id
-
1
));
params
.
put
(
"configId"
,
440
);
params
.
put
(
"configId"
,
440
);
params
.
put
(
"status"
,
0
);
params
.
put
(
"status"
,
0
);
params
.
put
(
"timeInterval"
,
"am"
);
params
.
put
(
"timeInterval"
,
"am"
);
...
@@ -286,7 +286,7 @@ public class Activity implements Authorization {
...
@@ -286,7 +286,7 @@ public class Activity implements Authorization {
sellerSubmitRecord
(
0
,
2
);
sellerSubmitRecord
(
0
,
2
);
//查询今日到场状态变为未到场
//查询今日到场状态变为未到场
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WX_submitRecordDetail
);
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WX_submitRecordDetail
);
int
signStatus
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户
4
\")}.signStatus"
);
int
signStatus
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户
0
\")}.signStatus"
);
Assert
.
assertEquals
(
signStatus
,
0
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已签到的签到状态非【未到场】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus
,
0
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已签到的签到状态非【未到场】"
,
response
.
body
().
asString
()));
}
}
...
@@ -348,7 +348,7 @@ public class Activity implements Authorization {
...
@@ -348,7 +348,7 @@ public class Activity implements Authorization {
int
unSubmitCount
=
response
.
jsonPath
().
getInt
(
"data.unSubmitCount"
);
int
unSubmitCount
=
response
.
jsonPath
().
getInt
(
"data.unSubmitCount"
);
Assert
.
assertEquals
(
faceCustCount
,
4
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderHeader
,
"见面客户数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
faceCustCount
,
4
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderHeader
,
"见面客户数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
submitCount
,
1
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderHeader
,
"已提交的销售专家数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
submitCount
,
1
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderHeader
,
"已提交的销售专家数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
unSubmitCount
,
3
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderHeader
,
"未提交的销售专家数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
unSubmitCount
,
4
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderHeader
,
"未提交的销售专家数错误"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"总监查看销售专家提报列表"
,
priority
=
20
)
@Test
(
description
=
"总监查看销售专家提报列表"
,
priority
=
20
)
...
@@ -359,7 +359,7 @@ public class Activity implements Authorization {
...
@@ -359,7 +359,7 @@ public class Activity implements Authorization {
params
.
put
(
"pageSize"
,
20
);
params
.
put
(
"pageSize"
,
20
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WX_leaderList
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WX_leaderList
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
Assert
.
assertEquals
(
size
,
4
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderList
,
"销售专家数数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
5
,
network
.
message
(
params
,
BasicConfig
.
WX_leaderList
,
"销售专家数数错误"
,
response
.
body
().
asString
()));
int
submitStatus1
=
response
.
jsonPath
().
getInt
(
"data.list.find{it.sellerName == '勿动-自动化测试专家'}.submitStatus"
);
int
submitStatus1
=
response
.
jsonPath
().
getInt
(
"data.list.find{it.sellerName == '勿动-自动化测试专家'}.submitStatus"
);
int
submitStatus2
=
response
.
jsonPath
().
getInt
(
"data.list.find{it.sellerName == '勿动-自动化测试带看'}.submitStatus"
);
int
submitStatus2
=
response
.
jsonPath
().
getInt
(
"data.list.find{it.sellerName == '勿动-自动化测试带看'}.submitStatus"
);
int
configStatistics1
=
response
.
jsonPath
().
getInt
(
"data.list.find{it.sellerName == '勿动-自动化测试专家'}.configStatistics.size()"
);
int
configStatistics1
=
response
.
jsonPath
().
getInt
(
"data.list.find{it.sellerName == '勿动-自动化测试专家'}.configStatistics.size()"
);
...
@@ -388,10 +388,10 @@ public class Activity implements Authorization {
...
@@ -388,10 +388,10 @@ public class Activity implements Authorization {
int
signStatus1
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户2\")}.signStatus"
);
int
signStatus1
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户2\")}.signStatus"
);
int
signStatus2
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户3\")}.signStatus"
);
int
signStatus2
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户3\")}.signStatus"
);
int
signStatus3
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户4\")}.signStatus"
);
int
signStatus3
=
response
.
jsonPath
().
getInt
(
"data.list[0].custList.find{it.custName.equals(\"自动化测试用户4\")}.signStatus"
);
Assert
.
assertEquals
(
signStatus0
,
2
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已到场的签到状态非【已签到
】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus0
,
0
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已到场的签到状态非【未到场
】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus1
,
0
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已鸽的签到状态非【未到场】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus1
,
0
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已鸽的签到状态非【未到场】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus2
,
2
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已签到的签到状态非【已签到】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus2
,
2
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已签到的签到状态非【已签到】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus3
,
0
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已签到的签到状态非【未到场
】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
signStatus3
,
2
,
network
.
message
(
params
,
BasicConfig
.
WX_submitRecordDetail
,
"已签到的签到状态非【已签到
】"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"总监查看专家今日非签到活动场景"
,
priority
=
22
)
@Test
(
description
=
"总监查看专家今日非签到活动场景"
,
priority
=
22
)
...
@@ -492,7 +492,7 @@ public class Activity implements Authorization {
...
@@ -492,7 +492,7 @@ public class Activity implements Authorization {
Response
response
=
network
.
getResponse
(
BasicConfig
.
WX_info
);
Response
response
=
network
.
getResponse
(
BasicConfig
.
WX_info
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.roles.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.roles.size()"
);
boolean
showSignDetailButton
=
response
.
jsonPath
().
getBoolean
(
"data.showSignDetailButton"
);
boolean
showSignDetailButton
=
response
.
jsonPath
().
getBoolean
(
"data.showSignDetailButton"
);
Assert
.
assertEquals
(
size
,
2
,
network
.
message
(
BasicConfig
.
WX_info
,
"登录人角色数错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
3
,
network
.
message
(
BasicConfig
.
WX_info
,
"登录人角色数错误"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
showSignDetailButton
,
network
.
message
(
BasicConfig
.
WX_info
,
"总监不可见签到详情"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
showSignDetailButton
,
network
.
message
(
BasicConfig
.
WX_info
,
"总监不可见签到详情"
,
response
.
body
().
asString
()));
}
}
...
@@ -534,8 +534,8 @@ public class Activity implements Authorization {
...
@@ -534,8 +534,8 @@ public class Activity implements Authorization {
@Test
(
description
=
"查询团队更新经营客户情况"
,
priority
=
40
)
@Test
(
description
=
"查询团队更新经营客户情况"
,
priority
=
40
)
public
void
查询团队更新经营客户情况
(){
public
void
查询团队更新经营客户情况
(){
otoLeaderAuth
();
otoLeaderAuth
();
checChart
(
1
,
3
,
1
);
checChart
(
1
,
4
,
0
);
checChart
(
2
,
5
,
0
);
checChart
(
2
,
1
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
5
,
0
,
0
);
checChart
(
5
,
0
,
0
);
...
@@ -546,8 +546,8 @@ public class Activity implements Authorization {
...
@@ -546,8 +546,8 @@ public class Activity implements Authorization {
public
void
上传
kyc
更新经营客户情况
(){
public
void
上传
kyc
更新经营客户情况
(){
saveKyc
(
cust_id
+
2
,
true
);
saveKyc
(
cust_id
+
2
,
true
);
saveKyc
(
cust_id
+
3
,
true
);
saveKyc
(
cust_id
+
3
,
true
);
checChart
(
1
,
3
,
1
);
checChart
(
1
,
4
,
0
);
checChart
(
2
,
4
,
0
);
checChart
(
2
,
0
,
0
);
checChart
(
3
,
1
,
0
);
checChart
(
3
,
1
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
5
,
0
,
0
);
checChart
(
5
,
0
,
0
);
...
@@ -559,8 +559,8 @@ public class Activity implements Authorization {
...
@@ -559,8 +559,8 @@ public class Activity implements Authorization {
otoPlanAuth
();
otoPlanAuth
();
savePlanFile
(
3
,
cust_id
+
2
);
savePlanFile
(
3
,
cust_id
+
2
);
savePlanFile
(
3
,
cust_id
+
3
);
savePlanFile
(
3
,
cust_id
+
3
);
checChart
(
1
,
3
,
1
);
checChart
(
1
,
4
,
1
);
checChart
(
2
,
4
,
0
);
checChart
(
2
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
4
,
1
,
0
);
checChart
(
4
,
1
,
0
);
checChart
(
5
,
0
,
0
);
checChart
(
5
,
0
,
0
);
...
@@ -571,8 +571,8 @@ public class Activity implements Authorization {
...
@@ -571,8 +571,8 @@ public class Activity implements Authorization {
public
void
上传解决方案更新经营客户情况
(){
public
void
上传解决方案更新经营客户情况
(){
savePlanFile
(
3
,
cust_id
+
2
);
savePlanFile
(
3
,
cust_id
+
2
);
savePlanFile
(
3
,
cust_id
+
3
);
savePlanFile
(
3
,
cust_id
+
3
);
checChart
(
1
,
3
,
1
);
checChart
(
1
,
4
,
1
);
checChart
(
2
,
4
,
0
);
checChart
(
2
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
5
,
1
,
0
);
checChart
(
5
,
1
,
0
);
...
@@ -584,8 +584,8 @@ public class Activity implements Authorization {
...
@@ -584,8 +584,8 @@ public class Activity implements Authorization {
otoLeaderAuth
();
otoLeaderAuth
();
promotionUpdate
(
cust_id
+
2
,
2
);
promotionUpdate
(
cust_id
+
2
,
2
);
promotionUpdate
(
cust_id
+
3
,
2
);
promotionUpdate
(
cust_id
+
3
,
2
);
checChart
(
1
,
3
,
1
);
checChart
(
1
,
4
,
1
);
checChart
(
2
,
4
,
0
);
checChart
(
2
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
3
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
4
,
0
,
0
);
checChart
(
5
,
0
,
0
);
checChart
(
5
,
0
,
0
);
...
...
src/test/java/com/oto/cases/otoseller/CheckTask.java
View file @
f2f6b7c8
...
@@ -66,7 +66,7 @@ public class CheckTask implements Authorization {
...
@@ -66,7 +66,7 @@ public class CheckTask implements Authorization {
public
void
查看可筛选标签列表
(){
public
void
查看可筛选标签列表
(){
Response
response
=
network
.
getResponse
(
BasicConfig
.
WORK_customerTagList
);
Response
response
=
network
.
getResponse
(
BasicConfig
.
WORK_customerTagList
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
Assert
.
assertEquals
(
size
,
2
,
network
.
message
(
BasicConfig
.
WORK_customerTagList
,
"查看可筛选标签数量正确"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
3
,
network
.
message
(
BasicConfig
.
WORK_customerTagList
,
"查看可筛选标签数量正确"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"标记和取消促单"
,
priority
=
5
)
@Test
(
description
=
"标记和取消促单"
,
priority
=
5
)
...
@@ -76,6 +76,7 @@ public class CheckTask implements Authorization {
...
@@ -76,6 +76,7 @@ public class CheckTask implements Authorization {
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
//查看客户的促单状态
//查看客户的促单状态
params
.
put
(
"custId"
,
cust_id
);
params
.
put
(
"type"
,
2
);
params
.
put
(
"type"
,
2
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
int
promotionType
=
response
.
jsonPath
().
getInt
(
"data.promotionType"
);
int
promotionType
=
response
.
jsonPath
().
getInt
(
"data.promotionType"
);
...
@@ -83,7 +84,6 @@ public class CheckTask implements Authorization {
...
@@ -83,7 +84,6 @@ public class CheckTask implements Authorization {
promotionUpdate
(
cust_id
,
0
);
promotionUpdate
(
cust_id
,
0
);
//查看客户的促单状态
//查看客户的促单状态
params
.
put
(
"type"
,
2
);
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
promotionType
=
response
.
jsonPath
().
getInt
(
"data.promotionType"
);
promotionType
=
response
.
jsonPath
().
getInt
(
"data.promotionType"
);
Assert
.
assertEquals
(
promotionType
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"客户的促单状态错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
promotionType
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"客户的促单状态错误"
,
response
.
body
().
asString
()));
...
@@ -109,7 +109,7 @@ public class CheckTask implements Authorization {
...
@@ -109,7 +109,7 @@ public class CheckTask implements Authorization {
@Test
(
description
=
"查询团队未盘点的未见面客户"
,
priority
=
7
)
@Test
(
description
=
"查询团队未盘点的未见面客户"
,
priority
=
7
)
public
void
查询团队未盘点的未见面客户
(){
public
void
查询团队未盘点的未见面客户
(){
checChart
(
1
,
6
,
0
);
checChart
(
1
,
5
,
0
);
}
}
@Test
(
description
=
"特定销售可见团队"
,
priority
=
9
)
@Test
(
description
=
"特定销售可见团队"
,
priority
=
9
)
...
@@ -876,11 +876,11 @@ public class CheckTask implements Authorization {
...
@@ -876,11 +876,11 @@ public class CheckTask implements Authorization {
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"deptIds"
,
new
int
[]{});
params
.
put
(
"deptIds"
,
new
int
[]{});
params
.
put
(
"expertIds"
,
new
int
[]{});
params
.
put
(
"expertIds"
,
new
int
[]{});
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_
abandonCus
t
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_
check_custChar
t
);
int
allNum
=
response
.
jsonPath
().
getInt
(
"data.fin
a
{it.custType == "
+
custType
+
"}.allCustNum"
);
int
allNum
=
response
.
jsonPath
().
getInt
(
"data.fin
d
{it.custType == "
+
custType
+
"}.allCustNum"
);
int
checkCusrNum
=
response
.
jsonPath
().
getInt
(
"data.fin
a
{it.custType == "
+
custType
+
"}.checkNum"
);
int
checkCusrNum
=
response
.
jsonPath
().
getInt
(
"data.fin
d
{it.custType == "
+
custType
+
"}.checkNum"
);
Assert
.
assertEquals
(
allNum
,
allCustNum
,
network
.
message
(
params
,
BasicConfig
.
WORK_
abandonCus
t
,
"客户类型为"
+
custType
+
"的总人数"
+
allCustNum
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
allNum
,
allCustNum
,
network
.
message
(
params
,
BasicConfig
.
WORK_
check_custChar
t
,
"客户类型为"
+
custType
+
"的总人数"
+
allCustNum
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
checkCusrNum
,
checkNum
,
network
.
message
(
params
,
BasicConfig
.
WORK_
abandonCus
t
,
"客户类型为"
+
custType
+
"的已盘点人数"
+
allCustNum
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
checkCusrNum
,
checkNum
,
network
.
message
(
params
,
BasicConfig
.
WORK_
check_custChar
t
,
"客户类型为"
+
custType
+
"的已盘点人数"
+
allCustNum
,
response
.
body
().
asString
()));
}
}
public
static
void
promotionUpdate
(
int
cust_id
,
int
promotionType
)
{
public
static
void
promotionUpdate
(
int
cust_id
,
int
promotionType
)
{
...
@@ -888,7 +888,7 @@ public class CheckTask implements Authorization {
...
@@ -888,7 +888,7 @@ public class CheckTask implements Authorization {
params
.
put
(
"custId"
,
cust_id
);
params
.
put
(
"custId"
,
cust_id
);
params
.
put
(
"promotionType"
,
promotionType
);
params
.
put
(
"promotionType"
,
promotionType
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_promotionUpdate
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_promotionUpdate
);
boolean
data
=
response
.
jsonPath
().
getBoolean
(
"data
"
);
boolean
success
=
response
.
jsonPath
().
getBoolean
(
"success
"
);
Assert
.
assertTrue
(
data
,
network
.
message
(
params
,
BasicConfig
.
WORK_promotionUpdate
,
"操作促单标识失败"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
success
,
network
.
message
(
params
,
BasicConfig
.
WORK_promotionUpdate
,
"操作促单标识失败"
,
response
.
body
().
asString
()));
}
}
}
}
src/test/java/com/oto/cases/otoseller/Phone.java
View file @
f2f6b7c8
...
@@ -462,7 +462,7 @@ public class Phone implements Authorization {
...
@@ -462,7 +462,7 @@ public class Phone implements Authorization {
otoTakerTku
();
otoTakerTku
();
Response
response
=
network
.
getResponse
(
BasicConfig
.
PHONE_expertList
);
Response
response
=
network
.
getResponse
(
BasicConfig
.
PHONE_expertList
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
Assert
.
assertEquals
(
size
,
2
,
network
.
message
(
BasicConfig
.
PHONE_expertList
,
"专家回显不为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
3
,
network
.
message
(
BasicConfig
.
PHONE_expertList
,
"专家回显不为空"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"查看我的面访状态更新为已完成"
,
priority
=
33
)
@Test
(
description
=
"查看我的面访状态更新为已完成"
,
priority
=
33
)
...
...
src/test/java/com/oto/cases/otoseller/Work.java
View file @
f2f6b7c8
...
@@ -87,6 +87,7 @@ public class Work implements Authorization {
...
@@ -87,6 +87,7 @@ public class Work implements Authorization {
otoLeaderAuth
();
otoLeaderAuth
();
tags
.
put
(
tagId
,
"勿动-自动化更新标签"
);
tags
.
put
(
tagId
,
"勿动-自动化更新标签"
);
tags
.
put
(
832
,
"自动化专家标签"
);
tagList
(
tags
);
tagList
(
tags
);
otoExpertAuth
();
otoExpertAuth
();
...
@@ -877,7 +878,7 @@ public class Work implements Authorization {
...
@@ -877,7 +878,7 @@ public class Work implements Authorization {
params
.
put
(
"name"
,
"自动化"
);
params
.
put
(
"name"
,
"自动化"
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_sellerList
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_sellerList
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
Assert
.
assertEquals
(
size
,
6
,
network
.
message
(
params
,
BasicConfig
.
WORK_sellerList
,
"当前跟进人模糊搜索数量错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
7
,
network
.
message
(
params
,
BasicConfig
.
WORK_sellerList
,
"当前跟进人模糊搜索数量错误"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"放弃客户进入回收池"
,
priority
=
65
)
@Test
(
description
=
"放弃客户进入回收池"
,
priority
=
65
)
...
@@ -913,7 +914,7 @@ public class Work implements Authorization {
...
@@ -913,7 +914,7 @@ public class Work implements Authorization {
String
custName
=
response
.
jsonPath
().
getString
(
"data.list[0].custName"
);
String
custName
=
response
.
jsonPath
().
getString
(
"data.list[0].custName"
);
String
custFromSourceDesc
=
response
.
jsonPath
().
getString
(
"data.list[0].custFromSourceDesc"
);
String
custFromSourceDesc
=
response
.
jsonPath
().
getString
(
"data.list[0].custFromSourceDesc"
);
int
custStatus
=
response
.
jsonPath
().
getInt
(
"data.list[0].custStatus"
);
int
custStatus
=
response
.
jsonPath
().
getInt
(
"data.list[0].custStatus"
);
Assert
.
assertEquals
(
custName
,
"自动化测试用户"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"客户姓名更新"
,
response
.
body
().
asString
()));
//
Assert.assertEquals(custName,"自动化测试用户",network.message(params,BasicConfig.MANAGER_oto_customerList,"客户姓名更新",response.body().asString()));
Assert
.
assertEquals
(
custFromSourceDesc
,
"投放客户-自建落地页-表单"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"客户来源未更新"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
custFromSourceDesc
,
"投放客户-自建落地页-表单"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"客户来源未更新"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
custStatus
,
0
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"客户的资源池错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
custStatus
,
0
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"客户的资源池错误"
,
response
.
body
().
asString
()));
...
@@ -979,7 +980,7 @@ public class Work implements Authorization {
...
@@ -979,7 +980,7 @@ public class Work implements Authorization {
params
.
put
(
"pageSize"
,
20
);
params
.
put
(
"pageSize"
,
20
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_getReservationList
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_getReservationList
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.size()"
);
Assert
.
assertEquals
(
size
,
3
,
network
.
message
(
BasicConfig
.
PHONE_getReservationList
,
"查看预约列表不为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
2
,
network
.
message
(
BasicConfig
.
PHONE_getReservationList
,
"查看预约列表不为空"
,
response
.
body
().
asString
()));
int
bookingStatus
=
response
.
jsonPath
().
getInt
(
"data[0].bookingStatus"
);
int
bookingStatus
=
response
.
jsonPath
().
getInt
(
"data[0].bookingStatus"
);
Assert
.
assertEquals
(
bookingStatus
,
0
,
network
.
message
(
BasicConfig
.
PHONE_getReservationList
,
"预约状态错误:非待参观"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
bookingStatus
,
0
,
network
.
message
(
BasicConfig
.
PHONE_getReservationList
,
"预约状态错误:非待参观"
,
response
.
body
().
asString
()));
...
@@ -1073,8 +1074,9 @@ public class Work implements Authorization {
...
@@ -1073,8 +1074,9 @@ public class Work implements Authorization {
params
.
put
(
"custPhoneNum"
,
custPhoneNum
);
params
.
put
(
"custPhoneNum"
,
custPhoneNum
);
params
.
put
(
"custName"
,
custName
);
params
.
put
(
"custName"
,
custName
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_introduce_save
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_introduce_save
);
boolean
data
=
response
.
jsonPath
().
getBoolean
(
"data"
);
boolean
success
=
response
.
jsonPath
().
getBoolean
(
"success"
);
Assert
.
assertEquals
(
data
,
result
,
network
.
message
(
params
,
BasicConfig
.
WORK_introduce_save
,
"创建转介绍客户结果非"
+
result
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
success
,
result
,
network
.
message
(
params
,
BasicConfig
.
WORK_introduce_save
,
"创建转介绍客户结果非"
+
result
,
response
.
body
().
asString
()));
}
}
}
}
src/test/java/com/oto/config/BasicConfig.java
View file @
f2f6b7c8
...
@@ -45,11 +45,11 @@ public class BasicConfig {
...
@@ -45,11 +45,11 @@ public class BasicConfig {
public
static
final
String
OTO_EXPERT_TKU
=
"7Fcuh7FWTsTHSpfadRRWCqKfrLzGwUzSt2GyKaN2k4JGQDTqw8BwHhYw3TyqyaYEjXrPE6fkTN8KHHHhhFKnjdfEt8mmziXNdVKTpV1oLBfQVLsLG32XkcYgX9nHtUA3r9bYDRhQGQp1y4AumVyQFbxr"
;
public
static
final
String
OTO_EXPERT_TKU
=
"7Fcuh7FWTsTHSpfadRRWCqKfrLzGwUzSt2GyKaN2k4JGQDTqw8BwHhYw3TyqyaYEjXrPE6fkTN8KHHHhhFKnjdfEt8mmziXNdVKTpV1oLBfQVLsLG32XkcYgX9nHtUA3r9bYDRhQGQp1y4AumVyQFbxr"
;
/*******OTO销售工作台-个微*********/
/*******OTO销售工作台-个微*********/
public
static
final
String
WX_CUSTOMER_TKU3
=
"3XE1uRL2Mq7DEPFFUMAtEgc1KZagjL4Bw7STUYA79h2mLaQExn9ji9MtuMqeigWxzYyLqGhdKFSWs18uFNXF74dZzMAuvJKHkLrc63b9erfkSoBQvM"
;
public
static
final
String
WX_CUSTOMER_TKU3
=
"3XE1uRL2Mq7DEPFFUMAtEgc1KZagjL4Bw7STUYA79h2mLaQExn9ji9MtuMqeigWxzYyLqGhdKFSWs18uFNXF74dZzMAuvJKHkLrc63b9erfkSoBQvM"
;
//userid:14
public
static
final
String
WX_CUSTOMER_TKU2
=
"3XE1uRL2Mq7DEPFFFRdnRPaPh4SXgsm35PhVj4M9pZEiBBjeEqjofm85tjBtZPBTzQoh68V4gcwq5RxvfTUzvU1HPrRRqU6Pji7JxkpeYD3PNZX7oH"
;
public
static
final
String
WX_CUSTOMER_TKU2
=
"3XE1uRL2Mq7DEPFFFRdnRPaPh4SXgsm35PhVj4M9pZEiBBjeEqjofm85tjBtZPBTzQoh68V4gcwq5RxvfTUzvU1HPrRRqU6Pji7JxkpeYD3PNZX7oH"
;
public
static
final
String
WX_CUSTOMER_TKU5
=
"3XE1uRL2Mq7DEPFFFRdnRPaTjtsHkF2ZD1idKAhmtGUvcqgpiFwyGQDqRFUnkryobzja88dJCcoixi4Locvda442c7y97vgtPidEaUhwXTot8J3VEG"
;
public
static
final
String
WX_CUSTOMER_TKU5
=
"3XE1uRL2Mq7DEPFFFRdnRPaTjtsHkF2ZD1idKAhmtGUvcqgpiFwyGQDqRFUnkryobzja88dJCcoixi4Locvda442c7y97vgtPidEaUhwXTot8J3VEG"
;
public
static
final
String
WX_EXPERT_TKU
=
"8WLT4bmESccxwWsdtyqvYAujdym8wr9EFgyuxyVTUn3bWkjBxCaRZ3Ab9Th23hEEHsVL89gYm26n7Eag4ZxYGhabwkN8voFamdmibepJZ7Jjinx"
;
public
static
final
String
WX_EXPERT_TKU
=
"8WLT4bmESccxwWsdtyqvYAujdym8wr9EFgyuxyVTUn3bWkjBxCaRZ3Ab9Th23hEEHsVL89gYm26n7Eag4ZxYGhabwkN8voFamdmibepJZ7Jjinx"
;
//userid:9
public
static
final
String
WX_LEADER_TKU
=
"8WLT4bmESccxwWsdtyqvYGjw2btb5QStHynN3Wqird53MakwdEDu5aNZEnV3PdpvmxipZ4bVxD7bjZKdofEdP9XVWgdNfNF52Vw1qV2dsf7gWVe"
;
public
static
final
String
WX_LEADER_TKU
=
"8WLT4bmESccxwWsdtyqvYGjw2btb5QStHynN3Wqird53MakwdEDu5aNZEnV3PdpvmxipZ4bVxD7bjZKdofEdP9XVWgdNfNF52Vw1qV2dsf7gWVe"
;
//userid:10
// *************** 客集集域名 ***************
// *************** 客集集域名 ***************
public
static
final
String
HOST
=
"https://kjj.m.duibatest.com.cn"
;
public
static
final
String
HOST
=
"https://kjj.m.duibatest.com.cn"
;
public
static
final
String
SSO_HOST
=
"https://sso.duibatest.com.cn"
;
public
static
final
String
SSO_HOST
=
"https://sso.duibatest.com.cn"
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment