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
d2562b50
Commit
d2562b50
authored
Sep 16, 2022
by
龚小红
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'Feature/20220914-gxh' into 'master'
Feature/20220914 gxh See merge request
!30
parents
c139ba66
909f17e4
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
20 deletions
+34
-20
Authorization.java
src/test/java/com/oto/cases/admin/Authorization.java
+4
-2
Phone.java
src/test/java/com/oto/cases/otoseller/Phone.java
+13
-13
Work.java
src/test/java/com/oto/cases/otoseller/Work.java
+15
-3
BasicConfig.java
src/test/java/com/oto/config/BasicConfig.java
+2
-2
No files found.
src/test/java/com/oto/cases/admin/Authorization.java
View file @
d2562b50
...
@@ -36,9 +36,11 @@ public interface Authorization {
...
@@ -36,9 +36,11 @@ public interface Authorization {
//久久保管理员-正常权限模式
//久久保管理员-正常权限模式
default
void
jjbManagerAuth
()
{
network
.
agentCookies
.
put
(
JJBManagerCookieKey
,
JJBManagerCookieValue
);}
default
void
jjbManagerAuth
()
{
network
.
agentCookies
.
put
(
JJBManagerCookieKey
,
JJBManagerCookieValue
);}
//oto销售工作台手机端-邀约销售
default
void
otoInviterTku
()
{
network
.
agentCookies
.
put
(
"tku"
,
OTO_INVITER_TKU
);
}
//oto销售工作台手机端-销售
//oto销售工作台手机端-
带看
销售
default
void
oto
SellerTku
()
{
network
.
agentCookies
.
put
(
"tku"
,
OTO
_TKU
);
}
default
void
oto
TakerTku
()
{
network
.
agentCookies
.
put
(
"tku"
,
OTO_TAKER
_TKU
);
}
/**
/**
* 集客助手相关授权
* 集客助手相关授权
...
...
src/test/java/com/oto/cases/otoseller/Phone.java
View file @
d2562b50
...
@@ -32,7 +32,7 @@ public class Phone implements Authorization {
...
@@ -32,7 +32,7 @@ public class Phone implements Authorization {
@BeforeTest
@BeforeTest
public
void
setUp
(){
public
void
setUp
(){
//登录销售工作台手机端
//登录销售工作台手机端
oto
Sell
erTku
();
oto
Tak
erTku
();
interviewIds
=
new
ArrayList
<>();
interviewIds
=
new
ArrayList
<>();
}
}
...
@@ -208,7 +208,7 @@ public class Phone implements Authorization {
...
@@ -208,7 +208,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"销售查询面访状态更新为授权失败"
,
priority
=
16
)
@Test
(
description
=
"销售查询面访状态更新为授权失败"
,
priority
=
16
)
public
void
销售查询面访状态更新为授权失败
()
{
public
void
销售查询面访状态更新为授权失败
()
{
sleep
(
1000
);
sleep
(
1000
);
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
...
@@ -226,7 +226,7 @@ public class Phone implements Authorization {
...
@@ -226,7 +226,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"销售查询面访状态更新为待上传"
,
priority
=
18
)
@Test
(
description
=
"销售查询面访状态更新为待上传"
,
priority
=
18
)
public
void
销售查询面访状态更新为待上传
()
{
public
void
销售查询面访状态更新为待上传
()
{
sleep
(
2000
);
sleep
(
2000
);
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
...
@@ -286,7 +286,7 @@ public class Phone implements Authorization {
...
@@ -286,7 +286,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"查看面访详情"
,
priority
=
22
)
@Test
(
description
=
"查看面访详情"
,
priority
=
22
)
public
void
查看面访详情
(){
public
void
查看面访详情
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
sleep
(
1000
);
sleep
(
1000
);
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
...
@@ -368,7 +368,7 @@ public class Phone implements Authorization {
...
@@ -368,7 +368,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"客户再次创建面访并扫码评价"
,
priority
=
28
)
@Test
(
description
=
"客户再次创建面访并扫码评价"
,
priority
=
28
)
public
void
客户再次创建面访并扫码评价
()
throws
SQLException
{
public
void
客户再次创建面访并扫码评价
()
throws
SQLException
{
oto
Sell
erTku
();
oto
Tak
erTku
();
interviewIds
.
clear
();
interviewIds
.
clear
();
interviewIds
.
add
(
saveInterview
(
cust_id
,
1
));
interviewIds
.
add
(
saveInterview
(
cust_id
,
1
));
...
@@ -381,7 +381,7 @@ public class Phone implements Authorization {
...
@@ -381,7 +381,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"查询失效面访回填信息"
,
priority
=
29
)
@Test
(
description
=
"查询失效面访回填信息"
,
priority
=
29
)
public
void
查询失效面访回填信息
(){
public
void
查询失效面访回填信息
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_custExtDetail
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_custExtDetail
);
...
@@ -395,7 +395,7 @@ public class Phone implements Authorization {
...
@@ -395,7 +395,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"上传社区参观面访详情"
,
priority
=
30
)
@Test
(
description
=
"上传社区参观面访详情"
,
priority
=
30
)
public
void
上传社区参观面访详情
(){
public
void
上传社区参观面访详情
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
int
[]
unusualTypes
=
{
2
};
int
[]
unusualTypes
=
{
2
};
int
[]
coreMakers
=
{
2
,
4
};
int
[]
coreMakers
=
{
2
,
4
};
...
@@ -455,7 +455,7 @@ public class Phone implements Authorization {
...
@@ -455,7 +455,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"创建送计划书面访"
,
priority
=
34
)
@Test
(
description
=
"创建送计划书面访"
,
priority
=
34
)
public
void
创建送计划书面访
(){
public
void
创建送计划书面访
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
interviewIds
.
add
(
saveInterview
(
cust_id
,
2
));
interviewIds
.
add
(
saveInterview
(
cust_id
,
2
));
}
}
...
@@ -470,7 +470,7 @@ public class Phone implements Authorization {
...
@@ -470,7 +470,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"查询异常通过面访回填信息"
,
priority
=
36
)
@Test
(
description
=
"查询异常通过面访回填信息"
,
priority
=
36
)
public
void
查询异常通过面访回填信息
(){
public
void
查询异常通过面访回填信息
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_custExtDetail
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_custExtDetail
);
...
@@ -483,7 +483,7 @@ public class Phone implements Authorization {
...
@@ -483,7 +483,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"二次正常扫码面访异常类型为空"
,
priority
=
37
)
@Test
(
description
=
"二次正常扫码面访异常类型为空"
,
priority
=
37
)
public
void
二次正常扫码面访异常类型为空
(){
public
void
二次正常扫码面访异常类型为空
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
params
.
put
(
"id"
,
interviewIds
.
get
(
0
));
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_getUnusualTypes
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_getUnusualTypes
);
...
@@ -512,7 +512,7 @@ public class Phone implements Authorization {
...
@@ -512,7 +512,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"产品下架后公司产品列表不显示"
,
priority
=
40
)
@Test
(
description
=
"产品下架后公司产品列表不显示"
,
priority
=
40
)
public
void
产品下架后公司产品列表不显示
()
{
public
void
产品下架后公司产品列表不显示
()
{
oto
Sell
erTku
();
oto
Tak
erTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custId"
,
cust_id
);
params
.
put
(
"custId"
,
cust_id
);
...
@@ -584,7 +584,7 @@ public class Phone implements Authorization {
...
@@ -584,7 +584,7 @@ public class Phone implements Authorization {
@Test
(
description
=
"查看我的日报为未提交"
,
priority
=
48
)
@Test
(
description
=
"查看我的日报为未提交"
,
priority
=
48
)
public
void
查看我的日报为未提交
(){
public
void
查看我的日报为未提交
(){
oto
Sell
erTku
();
oto
Tak
erTku
();
Response
response
=
network
.
getResponse
(
BasicConfig
.
PHONE_paper_getReportFlag
);
Response
response
=
network
.
getResponse
(
BasicConfig
.
PHONE_paper_getReportFlag
);
int
reportFlag
=
response
.
jsonPath
().
getInt
(
"data.reportFlag"
);
int
reportFlag
=
response
.
jsonPath
().
getInt
(
"data.reportFlag"
);
Assert
.
assertEquals
(
reportFlag
,
0
,
network
.
message
(
BasicConfig
.
PHONE_paper_getReportFlag
,
"日报提交状态非未提交"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
reportFlag
,
0
,
network
.
message
(
BasicConfig
.
PHONE_paper_getReportFlag
,
"日报提交状态非未提交"
,
response
.
body
().
asString
()));
...
@@ -598,7 +598,7 @@ public class Phone implements Authorization {
...
@@ -598,7 +598,7 @@ public class Phone implements Authorization {
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
Assert
.
assertTrue
(
size
>
0
,
network
.
message
(
BasicConfig
.
PHONE_paper_getCustomers
,
"订单状态未更新为已参观"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
size
>
0
,
network
.
message
(
BasicConfig
.
PHONE_paper_getCustomers
,
"订单状态未更新为已参观"
,
response
.
body
().
asString
()));
String
label
=
response
.
jsonPath
().
getString
(
"data.list[0].label"
);
String
label
=
response
.
jsonPath
().
getString
(
"data.list[0].label"
);
Assert
.
assertEquals
(
label
,
"今日
查看微信
"
,
network
.
message
(
BasicConfig
.
PHONE_paper_getCustomers
,
"日报提交状态非0:未提交"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
label
,
"今日
联系
"
,
network
.
message
(
BasicConfig
.
PHONE_paper_getCustomers
,
"日报提交状态非0:未提交"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"提交日报"
,
priority
=
50
)
@Test
(
description
=
"提交日报"
,
priority
=
50
)
...
...
src/test/java/com/oto/cases/otoseller/Work.java
View file @
d2562b50
...
@@ -231,8 +231,8 @@ public class Work implements Authorization {
...
@@ -231,8 +231,8 @@ public class Work implements Authorization {
Assert
.
assertNull
(
lastFollowTime
,
network
.
message
(
params
,
BasicConfig
.
WORK_customerList
,
"新客户的默认跟进时间不为null"
,
response
.
body
().
asString
()));
Assert
.
assertNull
(
lastFollowTime
,
network
.
message
(
params
,
BasicConfig
.
WORK_customerList
,
"新客户的默认跟进时间不为null"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"查
询客户手机号
"
,
priority
=
13
)
@Test
(
description
=
"查
看微信
"
,
priority
=
13
)
public
void
查
询客户手机号
(){
public
void
查
看微信
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"custId"
,
custId
);
params
.
put
(
"custId"
,
custId
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_phone
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
WORK_phone
);
...
@@ -464,6 +464,18 @@ public class Work implements Authorization {
...
@@ -464,6 +464,18 @@ public class Work implements Authorization {
Assert
.
assertEquals
(
size
,
1
,
network
.
message
(
BasicConfig
.
WORK_tagList
,
"跟进表格数量为空"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
size
,
1
,
network
.
message
(
BasicConfig
.
WORK_tagList
,
"跟进表格数量为空"
,
response
.
body
().
asString
()));
}
}
@Test
(
description
=
"查看日报客户列表"
,
priority
=
30
)
public
void
查看日报客户列表
(){
otoInviterTku
();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"pageSize"
,
20
);
Response
response
=
network
.
getResponse
(
params
,
BasicConfig
.
PHONE_paper_getCustomers
);
int
size
=
response
.
jsonPath
().
getInt
(
"data.list.size()"
);
Assert
.
assertTrue
(
size
>
0
,
network
.
message
(
BasicConfig
.
PHONE_paper_getCustomers
,
"订单状态未更新为已参观"
,
response
.
body
().
asString
()));
String
label
=
response
.
jsonPath
().
getString
(
"data.list[0].label"
);
Assert
.
assertEquals
(
label
,
"今日查看微信"
,
network
.
message
(
BasicConfig
.
PHONE_paper_getCustomers
,
"日报提交状态非0:未提交"
,
response
.
body
().
asString
()));
}
@Test
(
description
=
"修改客户基础信息"
,
priority
=
37
)
@Test
(
description
=
"修改客户基础信息"
,
priority
=
37
)
public
void
修改客户基础信息
(){
public
void
修改客户基础信息
(){
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<>();
...
@@ -1061,7 +1073,7 @@ public class Work implements Authorization {
...
@@ -1061,7 +1073,7 @@ public class Work implements Authorization {
params
.
clear
();
params
.
clear
();
String
acqList
[]
=
{
"01"
,
"02"
,
"03"
,
"04"
,
"05"
,
"06"
,
"07"
,
"08"
,
"09"
};
String
acqList
[]
=
{
"01"
,
"02"
,
"03"
,
"04"
,
"05"
,
"06"
,
"07"
,
"08"
,
"09"
};
params
.
put
(
"custSourceList"
,
acqList
);
//客户来源:
params
.
put
(
"custSourceList"
,
acqList
);
//客户来源:
params
.
put
(
"custType"
,
2
);
//1:全部客户;2:新客户;3:老客户
params
.
put
(
"custType"
,
3
);
//1:全部客户;2:新客户;3:老客户
params
.
put
(
"id"
,
4
);
params
.
put
(
"id"
,
4
);
params
.
put
(
"limitGoalFlag"
,
0
);
params
.
put
(
"limitGoalFlag"
,
0
);
params
.
put
(
"taskUsable"
,
1
);
//0:任务状态关闭;1:任务状态开启
params
.
put
(
"taskUsable"
,
1
);
//0:任务状态关闭;1:任务状态开启
...
...
src/test/java/com/oto/config/BasicConfig.java
View file @
d2562b50
...
@@ -36,8 +36,8 @@ public class BasicConfig {
...
@@ -36,8 +36,8 @@ public class BasicConfig {
public
static
final
String
dingTalkPath
=
"https://oapi.dingtalk.com/robot/send?access_token=e6fc528a3a5991ba74d800c9b1688bf5e0f4f88864ec92da777f84c260181407"
;
public
static
final
String
dingTalkPath
=
"https://oapi.dingtalk.com/robot/send?access_token=e6fc528a3a5991ba74d800c9b1688bf5e0f4f88864ec92da777f84c260181407"
;
/*******OTO销售工作台*********/
/*******OTO销售工作台*********/
// public static final String OTO
_TKU = "4yrzAfNog7WE527NKCNmqBqph48N7mWR9J49QYysZmKYC3DF97hQFap7RphynF3GFXLhp7GFZ35mc";
public
static
final
String
OTO_INVITER
_TKU
=
"4yrzAfNog7WE527NKCNmqBqph48N7mWR9J49QYysZmKYC3DF97hQFap7RphynF3GFXLhp7GFZ35mc"
;
public
static
final
String
OTO_TKU
=
"7Fcuh7FWTsTHSqd288vMyjAfN4Jz65xJY9UT76XsXSNJDjNBCoTd8saZJrKzeUKpKUaCyxwdMaoCbh4i7qdQbiiuhvxvhxw7GZ6P5yaWPkx6kp3CTwqww9AzAHJT5GAx941A662pYRtbM4Gkbcm15Dr5"
;
public
static
final
String
OTO_T
AKER_T
KU
=
"7Fcuh7FWTsTHSqd288vMyjAfN4Jz65xJY9UT76XsXSNJDjNBCoTd8saZJrKzeUKpKUaCyxwdMaoCbh4i7qdQbiiuhvxvhxw7GZ6P5yaWPkx6kp3CTwqww9AzAHJT5GAx941A662pYRtbM4Gkbcm15Dr5"
;
// *************** 客集集域名 ***************
// *************** 客集集域名 ***************
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