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
eeb7be0d
Commit
eeb7be0d
authored
Nov 09, 2022
by
龚小红
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'Feature/20221108/inviterTask' into 'master'
Feature/20221108/inviter task See merge request
!44
parents
573e21ec
fc104167
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
53 additions
and
11 deletions
+53
-11
Work.java
src/test/java/com/oto/cases/otoseller/Work.java
+52
-10
BasicConfig.java
src/test/java/com/oto/config/BasicConfig.java
+1
-1
No files found.
src/test/java/com/oto/cases/otoseller/Work.java
View file @
eeb7be0d
...
...
@@ -212,13 +212,13 @@ public class Work implements Authorization {
int
allCallTime
=
response
.
jsonPath
().
getInt
(
"data.allCallTime"
);
int
callTimes
=
response
.
jsonPath
().
getInt
(
"data.callTimes"
);
int
custStar
=
response
.
jsonPath
().
getInt
(
"data.custStar"
);
int
addWxStatus
=
response
.
jsonPath
().
getInt
(
"data.
custStar
"
);
int
addWxStatus
=
response
.
jsonPath
().
getInt
(
"data.
addWxStatus
"
);
String
custHead
=
response
.
jsonPath
().
getString
(
"data.custHead"
);
String
custDescription
=
response
.
jsonPath
().
getString
(
"data.custDescription"
);
String
expertRemark
=
response
.
jsonPath
().
getString
(
"data.expertRemark"
);
Assert
.
assertEquals
(
allCallTimes
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总
通话
次数非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
allCallTime
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总
call次数
非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
callTimes
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话
时间
非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
allCallTimes
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总
call
次数非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
allCallTime
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总
通话时间
非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
callTimes
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话
次数
非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
custStar
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户星标不为否"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
addWxStatus
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户的加微状态不是未添加"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
custHead
,
"https://yun.kjjcrm.com/kjy/media/file/20221018/c9c37c521ddfd949614f1b78b92a1001.png?x-oss-process=image/quality,q_80"
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户头像非默认头像"
,
response
.
body
().
asString
()));
...
...
@@ -1482,10 +1482,10 @@ public class Work implements Authorization {
public
void
邀约完成任务
(){
otoInviterAuth
();
//notDeal -未接通,dealing-已接通
callling
(
"15136361301"
,
"notDeal"
);
callling
(
"15136361301"
,
"notDeal"
);
callling
(
"15136361302"
,
"notDeal"
);
callling
(
"15136361303"
,
"dealing"
);
callling
(
"15136361301"
,
0
,
"notDeal"
);
callling
(
"15136361301"
,
0
,
"notDeal"
);
callling
(
"15136361302"
,
0
,
"notDeal"
);
callling
(
"15136361303"
,
30
,
"dealing"
);
//销售完成面访,跟进时间更新,联系新客户任务完成
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"taskConfId"
,
7
);
//任务配置id,4:联系未跟进的客户,5:复拨未接通的客户,6:超过N天未跟进的客户
...
...
@@ -1496,6 +1496,48 @@ public class Work implements Authorization {
Assert
.
assertEquals
(
finishCustNum
,
2
,
network
.
message
(
params
,
BasicConfig
.
WORK_taskList
,
"已完成数量记录错误"
,
response
.
body
().
asString
()));
}
@Test
(
description
=
"校验通话后显示回填弹窗"
,
priority
=
106
)
public
void
校验通话后显示回填弹窗
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custId"
,
custId
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_showFeedback
);
boolean
data
=
response
.
jsonPath
().
getBoolean
(
"data"
);
Assert
.
assertTrue
(
data
,
network
.
message
(
params
,
BasicConfig
.
WORK_showFeedback
,
"电话表单回填状态错误:为不需要回填"
,
response
.
body
().
asString
()));
params
.
put
(
"custId"
,
custId
+
2
);
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_showFeedback
);
data
=
response
.
jsonPath
().
getBoolean
(
"data"
);
Assert
.
assertTrue
(
data
,
network
.
message
(
params
,
BasicConfig
.
WORK_showFeedback
,
"电话表单回填状态错误:为不需要回填"
,
response
.
body
().
asString
()));
}
@Test
(
description
=
"校验邀约的通话信息"
,
priority
=
107
)
public
void
校验邀约的通话信息
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"type"
,
1
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
int
allCallTimes
=
response
.
jsonPath
().
getInt
(
"data.allCallTimes"
);
int
allCallTime
=
response
.
jsonPath
().
getInt
(
"data.allCallTime"
);
int
callTimes
=
response
.
jsonPath
().
getInt
(
"data.callTimes"
);
String
lastCallTime
=
response
.
jsonPath
().
getString
(
"data.lastCallTime"
);
Assert
.
assertEquals
(
allCallTimes
,
2
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总call次数非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
allCallTime
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话时间非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
callTimes
,
0
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话次数非0"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
lastCallTime
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话次数非0"
,
response
.
body
().
asString
()));
params
.
put
(
"custId"
,
custId
+
2
);
params
.
put
(
"type"
,
1
);
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_header
);
allCallTimes
=
response
.
jsonPath
().
getInt
(
"data.allCallTimes"
);
allCallTime
=
response
.
jsonPath
().
getInt
(
"data.allCallTime"
);
callTimes
=
response
.
jsonPath
().
getInt
(
"data.callTimes"
);
lastCallTime
=
response
.
jsonPath
().
getString
(
"data.lastCallTime"
);
Assert
.
assertEquals
(
allCallTimes
,
1
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总call次数非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
allCallTime
,
30
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话时间非0"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
callTimes
,
1
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话次数非0"
,
response
.
body
().
asString
()));
Assert
.
assertNotNull
(
lastCallTime
,
network
.
message
(
params
,
BasicConfig
.
WORK_header
,
"新客户总通话次数非0"
,
response
.
body
().
asString
()));
}
//修改客户的约面情况
public
void
updateInvite
(
int
interviewFlag
,
long
time
){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
...
...
@@ -1662,9 +1704,9 @@ public class Work implements Authorization {
}
}
public
void
callling
(
String
custPhone
,
String
callState
){
public
void
callling
(
String
custPhone
,
int
length
,
String
callState
){
//销售完成面访,跟进时间更新,联系新客户任务完成
String
CALL_URL
=
CALL_BACK_1
+
custPhone
+
CALL_BACK_2
+
callState
+
CALL_BACK_3
;
String
CALL_URL
=
CALL_BACK_1
+
custPhone
+
CALL_BACK_2
+
length
+
"&State="
+
callState
+
CALL_BACK_3
;
Response
response
=
network
.
getResponse
(
CALL_URL
);
}
...
...
src/test/java/com/oto/config/BasicConfig.java
View file @
eeb7be0d
...
...
@@ -256,7 +256,7 @@ public class BasicConfig {
public
static
final
String
WORK_delCust
=
WORK_HOST
+
"/kjy/oto/auto/test/delCust"
;
public
static
final
String
WORK_delPubFormRecord
=
WORK_HOST
+
"/kjy/oto/auto/test/delPubFormRecord"
;
public
static
final
String
CALL_BACK_1
=
WORK_HOST
+
"/kjy/oto/notify/record?CallSheetID=e7b4efe0-e7bc-4fc1-9ce8-d7655dccc8cd&CallID=e7b4efe0-e7bc-4fc1-9ce8-d7655dccc8cd&CallType=dialout&CallNo=18248405155&CalledNo="
;
public
static
final
String
CALL_BACK_2
=
"&Ring=2022-11-07%2013:57:06&RingingTime=&Begin=2022-11-07%2013:57:14&End=2022-11-07%2013:57:28&CallTimeLength=
0&State=
"
;
public
static
final
String
CALL_BACK_2
=
"&Ring=2022-11-07%2013:57:06&RingingTime=&Begin=2022-11-07%2013:57:14&End=2022-11-07%2013:57:28&CallTimeLength="
;
public
static
final
String
CALL_BACK_3
=
"&MonitorFilename=http://work-phone-record.oss-cn-beijing.aliyuncs.com/20221103/20221103135706_16621273912_136****3947_e7b4efe0-e7bc-4fc1-9ce8-d7655dccc8cd.mp3&RecordFile=20221103/20221103135706_16621273912_136****3947_e7b4efe0-e7bc-4fc1-9ce8-d7655dccc8cd.mp3&FileServer=http://work-phone-record.oss-cn-beijing.aliyuncs.com/&ring=2022-11-07%2013:57:06"
;
//*************** 人管系统 ***************
...
...
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