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
d28a63c6
Commit
d28a63c6
authored
Jan 31, 2023
by
龚小红
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改上传方案和分配角色用例
parent
a5a4bb8a
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
10 deletions
+12
-10
Phone.java
src/test/java/com/oto/cases/otoseller/Phone.java
+4
-7
Work.java
src/test/java/com/oto/cases/otoseller/Work.java
+8
-3
No files found.
src/test/java/com/oto/cases/otoseller/Phone.java
View file @
d28a63c6
...
@@ -258,7 +258,7 @@ public class Phone implements Authorization {
...
@@ -258,7 +258,7 @@ public class Phone implements Authorization {
Assert
.
assertNotNull
(
interviewAddress
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"客户地址回显为空"
,
response
.
body
().
asString
()));
Assert
.
assertNotNull
(
interviewAddress
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"客户地址回显为空"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
giveProspectusFlag
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否可送计划书回显不为空"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
giveProspectusFlag
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否可送计划书回显不为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
commitPlanFlag
,
0
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书回显不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
commitPlanFlag
,
0
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书回显不为否"
,
response
.
body
().
asString
()));
Assert
.
assert
Null
(
expertName
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"专家回显不为空"
,
response
.
body
().
asString
()));
Assert
.
assert
Equals
(
expertName
,
"勿动-自动化测试专家"
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"专家回显不为空"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"上传第一次社区参观面访详情"
,
priority
=
21
)
@Test
(
description
=
"上传第一次社区参观面访详情"
,
priority
=
21
)
...
@@ -324,7 +324,7 @@ public class Phone implements Authorization {
...
@@ -324,7 +324,7 @@ public class Phone implements Authorization {
response
=
network
.
getResponse
(
selectParams
,
BasicConfig
.
MANAGER_oto_customerList
);
response
=
network
.
getResponse
(
selectParams
,
BasicConfig
.
MANAGER_oto_customerList
);
String
sellerName
=
response
.
jsonPath
().
getString
(
"data.list[0].sellerVo.sellerName"
);
String
sellerName
=
response
.
jsonPath
().
getString
(
"data.list[0].sellerVo.sellerName"
);
String
expertName
=
response
.
jsonPath
().
getString
(
"data.list[0].expertVo.sellerName"
);
String
expertName
=
response
.
jsonPath
().
getString
(
"data.list[0].expertVo.sellerName"
);
Assert
.
assertEquals
(
expertName
,
"勿动-自动化测试
总监
"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"修改客户标签失败"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
expertName
,
"勿动-自动化测试
专家
"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"修改客户标签失败"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
sellerName
,
"勿动-自动化测试带看"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"修改客户标签失败"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
sellerName
,
"勿动-自动化测试带看"
,
network
.
message
(
params
,
BasicConfig
.
MANAGER_oto_customerList
,
"修改客户标签失败"
,
response
.
body
().
asString
()));
}
}
...
@@ -408,7 +408,7 @@ public class Phone implements Authorization {
...
@@ -408,7 +408,7 @@ public class Phone implements Authorization {
Assert
.
assertNull
(
followWeight
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"客户等级回显不为1"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
followWeight
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"客户等级回显不为1"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
giveProspectusFlag
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否可送计划书不为空"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
giveProspectusFlag
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否可送计划书不为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
commitPlanFlag
,
0
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
commitPlanFlag
,
0
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
expertName
,
"勿动-自动化测试
总监
"
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"专家回显错误,非【勿动-自动化测试专家】"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
expertName
,
"勿动-自动化测试
专家
"
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"专家回显错误,非【勿动-自动化测试专家】"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"上传社区参观面访详情"
,
priority
=
30
)
@Test
(
description
=
"上传社区参观面访详情"
,
priority
=
30
)
...
@@ -510,7 +510,7 @@ public class Phone implements Authorization {
...
@@ -510,7 +510,7 @@ public class Phone implements Authorization {
String
expertName
=
response
.
jsonPath
().
getString
(
"data.expertName"
);
String
expertName
=
response
.
jsonPath
().
getString
(
"data.expertName"
);
Assert
.
assertEquals
(
giveProspectusFlag
,
1
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否可送计划书不为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
giveProspectusFlag
,
1
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否可送计划书不为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
commitPlanFlag
,
0
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
commitPlanFlag
,
0
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
expertName
,
"勿动-自动化测试
总监
"
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
expertName
,
"勿动-自动化测试
专家
"
,
network
.
message
(
params
,
BasicConfig
.
PHONE_custExtDetail
,
"是否已送计划书不为否"
,
response
.
body
().
asString
()));
}
}
...
@@ -668,9 +668,6 @@ public class Phone implements Authorization {
...
@@ -668,9 +668,6 @@ public class Phone implements Authorization {
public
void
专家能查看关联自己的面访
(){
public
void
专家能查看关联自己的面访
(){
otoEpertTku
();
otoEpertTku
();
long
id
=
IdMakeUtil
.
decodingId
(
cust_id
);
assignSeller
((
int
)
id
,
EXPERT_ID
,
true
,
3
);
//分配给专家
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custName"
,
"自动化激活用户"
);
params
.
put
(
"custName"
,
"自动化激活用户"
);
params
.
put
(
"pageSize"
,
"20"
);
params
.
put
(
"pageSize"
,
"20"
);
...
...
src/test/java/com/oto/cases/otoseller/Work.java
View file @
d28a63c6
...
@@ -126,8 +126,10 @@ public class Work implements Authorization {
...
@@ -126,8 +126,10 @@ public class Work implements Authorization {
public
void
公域引流
_
分配客户
(){
public
void
公域引流
_
分配客户
(){
assignSeller
(
custId
,
23
,
false
,
1
);
assignSeller
(
custId
,
23
,
false
,
1
);
sleep
(
1000
);
assignSeller
(
custId
,
INVITE_ID
,
true
,
1
);
assignSeller
(
custId
,
INVITE_ID
,
true
,
1
);
sleep
(
1000
);
assignSeller
(
custId
+
3
,
320
,
true
,
1
);
assignSeller
(
custId
+
3
,
320
,
true
,
1
);
// for(int i = 6104;i<6204;i++){
// for(int i = 6104;i<6204;i++){
...
@@ -951,16 +953,18 @@ public class Work implements Authorization {
...
@@ -951,16 +953,18 @@ public class Work implements Authorization {
@Test
(
description
=
"查看回收池客户列表"
,
priority
=
67
)
@Test
(
description
=
"查看回收池客户列表"
,
priority
=
67
)
public
void
查看回收池客户列表
(){
public
void
查看回收池客户列表
(){
otoManagerAuth
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"pageIndex"
,
1
);
params
.
put
(
"pageIndex"
,
1
);
params
.
put
(
"pageSize"
,
20
);
params
.
put
(
"pageSize"
,
20
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_recycleList
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_recycleList
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
Assert
.
assertTrue
(
size
>
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_recycleList
,
"查看回收池客户列表为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_recycleList
,
"查看回收池客户列表为空"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"认领回收池客户"
,
priority
=
68
)
@Test
(
description
=
"认领回收池客户"
,
priority
=
68
)
public
void
认领回收池客户
(){
public
void
认领回收池客户
(){
otoInviterAuth
();
sleep
(
2000
);
sleep
(
2000
);
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"custId"
,
custId
);
...
@@ -1828,7 +1832,7 @@ public class Work implements Authorization {
...
@@ -1828,7 +1832,7 @@ public class Work implements Authorization {
boolean
hasFollowFlag
=
response
.
jsonPath
().
getBoolean
(
"data.hasFollowFlag"
);
boolean
hasFollowFlag
=
response
.
jsonPath
().
getBoolean
(
"data.hasFollowFlag"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.roleTypes.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.roleTypes.size()"
);
Assert
.
assertTrue
(
hasFollowFlag
,
network
.
message
(
params
,
BasicConfig
.
WORK_getFollowInfo
,
"客户没有销售或专家跟进"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
hasFollowFlag
,
network
.
message
(
params
,
BasicConfig
.
WORK_getFollowInfo
,
"客户没有销售或专家跟进"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
1
,
network
.
message
(
params
,
BasicConfig
.
WORK_getFollowInfo
,
"客户的跟进角色错误"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
2
,
network
.
message
(
params
,
BasicConfig
.
WORK_getFollowInfo
,
"客户的跟进角色错误"
,
response
.
body
().
asString
()));
}
}
...
@@ -1961,11 +1965,12 @@ public class Work implements Authorization {
...
@@ -1961,11 +1965,12 @@ public class Work implements Authorization {
public
void
上传客户方案
(){
public
void
上传客户方案
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"planFile
"
,
"//yun.dui88.com/kjy/media/file/20230113/20230113145555/1.doc"
);
params
.
put
(
"planFile
s"
,
new
String
[]{
"//yun.dui88.com/kjy/media/file/20230113/20230113145555/1.doc"
,
"//yun.dui88.com/kjy/media/file/20230131/20230131111229/4.ppt"
}
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_planFileUpload
);
Response
response
=
network
.
postResponse
(
params
,
BasicConfig
.
WORK_planFileUpload
);
boolean
data
=
response
.
jsonPath
().
getBoolean
(
"data"
);
boolean
data
=
response
.
jsonPath
().
getBoolean
(
"data"
);
Assert
.
assertTrue
(
data
,
network
.
message
(
params
,
BasicConfig
.
WORK_planFileUpload
,
"上传客户方案失败"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
data
,
network
.
message
(
params
,
BasicConfig
.
WORK_planFileUpload
,
"上传客户方案失败"
,
response
.
body
().
asString
()));
params
.
clear
();
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"type"
,
2
);
params
.
put
(
"type"
,
2
);
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
...
...
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