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
5e6a7d12
Commit
5e6a7d12
authored
Jul 28, 2021
by
xiamengchen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码存档
parent
4254bf77
Changes
10
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
927 additions
and
152 deletions
+927
-152
ArticlePage.java
src/test/java/com/kjj/bean/assistant/ArticlePage.java
+9
-0
RankingList.java
src/test/java/com/kjj/bean/assistant/RankingList.java
+8
-0
Authorization.java
src/test/java/com/kjj/cases/admin/Authorization.java
+88
-48
GameLottery.java
...java/com/kjj/cases/assistant/markettools/GameLottery.java
+2
-2
GreetingCrad.java
...ava/com/kjj/cases/assistant/markettools/GreetingCrad.java
+1
-1
ForwardAndRead.java
...java/com/kjj/cases/assistant/whoSawMe/ForwardAndRead.java
+17
-5
MyCustomer.java
...est/java/com/kjj/cases/assistant/whoSawMe/MyCustomer.java
+442
-0
MyForward.java
...test/java/com/kjj/cases/assistant/whoSawMe/MyForward.java
+1
-3
WhoSawMe.java
src/test/java/com/kjj/cases/assistant/whoSawMe/WhoSawMe.java
+315
-91
BasicConfig.java
src/test/java/com/kjj/config/BasicConfig.java
+44
-2
No files found.
src/test/java/com/kjj/bean/assistant/ArticlePage.java
0 → 100644
View file @
5e6a7d12
package
com
.
kjj
.
bean
.
assistant
;
import
lombok.Data
;
@Data
public
class
ArticlePage
{
private
String
contentType
;
private
String
contentId
;
}
src/test/java/com/kjj/bean/assistant/RankingList.java
0 → 100644
View file @
5e6a7d12
package
com
.
kjj
.
bean
.
assistant
;
import
lombok.Data
;
@Data
public
class
RankingList
{
private
String
sellerId
;
}
src/test/java/com/kjj/cases/admin/Authorization.java
View file @
5e6a7d12
...
@@ -20,8 +20,9 @@ public interface Authorization {
...
@@ -20,8 +20,9 @@ public interface Authorization {
System
.
out
.
println
(
"用户AUTH_KEY:"
+
ADMIN_KEY
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
ADMIN_KEY
);
}
}
/**
/**
* 集客助手
相关
授权
* 集客助手授权
*/
*/
//代理人
//代理人
default
void
agentTku
()
{
default
void
agentTku
()
{
...
@@ -30,191 +31,230 @@ public interface Authorization {
...
@@ -30,191 +31,230 @@ public interface Authorization {
}
}
// 获取访客tku:Su Yi
//代理人
default
void
userTku
()
{
default
void
visitor2Tku
()
{
network
.
agentCookies
.
put
(
"tku"
,
VISITOR_UserTku
);
network
.
agentCookies
.
put
(
"tku"
,
VISITOR2_TKU
);
System
.
out
.
println
(
"访客tku:"
+
VISITOR_UserTku
);
System
.
out
.
println
(
"代理人tku:"
+
VISITOR2_TKU
);
}
}
// 获取访客tku
:请勿打扰
// 获取访客tku
default
void
userTku
1
()
{
default
void
userTku
()
{
network
.
agentCookies
.
put
(
"tku"
,
VISITOR_TKU
);
network
.
agentCookies
.
put
(
"tku"
,
VISITOR_TKU
);
System
.
out
.
println
(
"访客tku:"
+
VISITOR_TKU
);
System
.
out
.
println
(
"访客tku:"
+
VISITOR_TKU
);
}
}
// 获取访客tku:小雪人
default
void
userTku2
()
{
network
.
agentCookies
.
put
(
"tku"
,
VISITOR1_TKU
);
System
.
out
.
println
(
"访客tku:"
+
VISITOR1_TKU
);
}
/**
/**
*
直播业务相关
*
代理人(yl)授权,ID:826
*/
*/
//代理人(yl)授权,ID:826
default
void
agentAuth
(){
default
void
agentAuth
(){
// 创建用户 并传到network里
// 创建用户 并传到network里
network
.
agentCookies
.
put
(
"authKey"
,
AUTH_KEY
);
network
.
agentCookies
.
put
(
"authKey"
,
AUTH_KEY
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
AUTH_KEY
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
AUTH_KEY
);
}
}
/**
//代理人(小疙瘩人寿)授权,ID:995
* 代理人(小疙瘩人寿)授权,ID:995
*/
default
void
agentAuth1
(){
default
void
agentAuth1
(){
// 创建用户 并传到network里
// 创建用户 并传到network里
network
.
agentCookies
.
put
(
"authKey"
,
agentAuth
);
network
.
agentCookies
.
put
(
"authKey"
,
agentAuth
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
agentAuth
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
agentAuth
);
}
}
//访客A(志勇)授权,代理人指定中奖用户,ID:107
/**
* 访客A(志勇)授权,代理人指定中奖用户,ID:107
*/
default
void
visitorAuth
()
{
default
void
visitorAuth
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth
);
}
}
//访客B(茶仔)授权,用户ID:122
/**
* 访客B(茶仔)授权,用户ID:122
*/
default
void
visitorAuth2
()
{
default
void
visitorAuth2
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth2
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth2
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth2
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth2
);
}
}
//访客C(刘超)授权,地域指定用户ID:811
/**
* 访客C(刘超)授权,地域指定用户ID:811
*/
default
void
visitorAuth3
()
{
default
void
visitorAuth3
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth3
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth3
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth3
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth3
);
}
}
//访客D(李执)授权,地域指定用户ID:89
/**
* 访客D(李执)授权,地域指定用户ID:89
*/
default
void
visitorAuth4
()
{
default
void
visitorAuth4
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth4
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth4
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth4
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth4
);
}
}
/**
//访客E(周成)授权,企业指定中奖用户,用户ID:812
* 访客E(周成)授权,企业指定中奖用户,用户ID:812
*/
default
void
visitorAuth5
()
{
default
void
visitorAuth5
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth5
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth5
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth5
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth5
);
}
}
//访客F(新强)授权,用户ID:82
/**
* 访客F(新强)授权,用户ID:82
*/
default
void
visitorAuth6
()
{
default
void
visitorAuth6
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth6
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth6
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth6
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth6
);
}
}
//访客G(熊二)授权,黑名单用户,ID:719
/**
* 访客G(熊二)授权,黑名单用户,ID:719
*/
default
void
visitorAuth7
()
{
default
void
visitorAuth7
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth7
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth7
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth7
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth7
);
}
}
//访客I(熊大)授权 ID:1239
/**
* 访客I(熊大)授权 ID:1239
*/
default
void
visitorAuth8
()
{
default
void
visitorAuth8
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth8
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth8
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth8
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth8
);
}
}
/**
//访客H(吉吉)非实名用户授权,ID:907
* 访客H(吉吉)非实名用户授权,ID:907
*/
default
void
visitorAuth9
()
{
default
void
visitorAuth9
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth9
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth9
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth9
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth9
);
}
}
//访客J(日落)授权,ID:703
/**
* 访客J(日落)授权,ID:703
*/
default
void
visitorAuth10
()
{
default
void
visitorAuth10
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth10
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth10
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth10
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth10
);
}
}
//访客K(沈小四)授权,ID:108
/**
* 访客K(沈小四)授权,ID:108
*/
default
void
visitorAuth11
()
{
default
void
visitorAuth11
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth11
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth11
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth11
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth11
);
}
}
//访客L(饺子)授权,ID:97
/**
* 访客L(饺子)授权,ID:97
*/
default
void
visitorAuth12
()
{
default
void
visitorAuth12
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth12
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth12
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth12
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth12
);
}
}
//访客M(大妹子)非实名用户授权,ID:299
/**
* 访客M(大妹子)非实名用户授权,ID:299
*/
default
void
visitorAuth13
()
{
default
void
visitorAuth13
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth13
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth13
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth13
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth13
);
}
}
//访客N(光头强)非实名用户授权,ID:540
/**
* 访客N(光头强)非实名用户授权,ID:540
*/
default
void
visitorAuth14
()
{
default
void
visitorAuth14
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth14
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth14
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth14
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth14
);
}
}
//访客O(少侠)授权,ID:79
/**
* 访客O(少侠)授权,ID:79
*/
default
void
visitorAuth15
()
{
default
void
visitorAuth15
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth15
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth15
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth15
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth15
);
}
}
//访客P(抬头有飞碟)授权,ID:99
/**
* 访客P(抬头有飞碟)授权,ID:99
*/
default
void
visitorAuth16
()
{
default
void
visitorAuth16
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth16
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth16
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth16
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth16
);
}
}
//访客Q(枫城)授权,ID:77
/**
* 访客Q(枫城)授权,ID:77
*/
default
void
visitorAuth17
()
{
default
void
visitorAuth17
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth17
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth17
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth17
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth17
);
}
}
//访客R(小老弟来了)非实名用户授权,ID:94
/**
* 访客R(小老弟来了)非实名用户授权,ID:94
*/
default
void
visitorAuth18
()
{
default
void
visitorAuth18
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth18
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth18
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth18
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth18
);
}
}
//访客T(林国芸)ID:786
/**
* 访客T(林国芸)ID:786
*/
default
void
visitorAuth19
()
{
default
void
visitorAuth19
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth19
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth19
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth19
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth19
);
}
}
//访客Y(孙心桂)ID:785
/**
* 访客Y(孙心桂)ID:785
*/
default
void
visitorAuth20
()
{
default
void
visitorAuth20
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth20
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth20
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth20
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth20
);
}
}
//访客W(谢翊美)ID:791
/**
* 访客W(谢翊美)ID:791
*/
default
void
visitorAuth21
()
{
default
void
visitorAuth21
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth21
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth21
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth21
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth21
);
}
}
//访客V(zzz666)ID:849
/**
* 访客V(zzz666)ID:849
*/
default
void
visitorAuth22
()
{
default
void
visitorAuth22
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth22
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth22
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth22
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth22
);
}
}
//访客u(七凉)ID:179
/**
* 访客u(七凉)ID:179
*/
default
void
visitorAuth23
()
{
default
void
visitorAuth23
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth23
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth23
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth23
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth23
);
}
}
//访客S(奶汪)ID:1170 实名
/**
* 访客S(奶汪)ID:1170 实名
*/
default
void
visitorAuth24
()
{
default
void
visitorAuth24
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth24
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth24
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth24
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth24
);
}
}
//访客S(亦心)ID:96 实名
/**
* 访客S(亦心)ID:96 实名
*/
default
void
visitorAuth25
()
{
default
void
visitorAuth25
()
{
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth25
);
network
.
agentCookies
.
put
(
"authKey"
,
visitorAuth25
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth25
);
System
.
out
.
println
(
"用户AUTH_KEY:"
+
visitorAuth25
);
...
...
src/test/java/com/kjj/cases/assistant/markettools/GameLottery.java
View file @
5e6a7d12
...
@@ -298,7 +298,7 @@ public class GameLottery implements Authorization {
...
@@ -298,7 +298,7 @@ public class GameLottery implements Authorization {
@Test
(
description
=
"访客_打开抽奖链接"
,
priority
=
13
)
@Test
(
description
=
"访客_打开抽奖链接"
,
priority
=
13
)
public
void
访客
_
打开抽奖链接
(){
public
void
访客
_
打开抽奖链接
(){
//切换为访客-请勿打扰
//切换为访客-请勿打扰
userTku1
();
//
userTku1();
//添加访问记录
//添加访问记录
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
...
@@ -541,7 +541,7 @@ public class GameLottery implements Authorization {
...
@@ -541,7 +541,7 @@ public class GameLottery implements Authorization {
@Test
(
description
=
"访客_第二个客户未中奖"
,
priority
=
21
)
@Test
(
description
=
"访客_第二个客户未中奖"
,
priority
=
21
)
public
void
访客
_
第二个客户未中奖
(){
public
void
访客
_
第二个客户未中奖
(){
//切换为请勿打扰
//切换为请勿打扰
userTku1
();
//
userTku1();
//添加访问记录
//添加访问记录
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
...
...
src/test/java/com/kjj/cases/assistant/markettools/GreetingCrad.java
View file @
5e6a7d12
...
@@ -658,7 +658,7 @@ public class GreetingCrad implements Authorization{
...
@@ -658,7 +658,7 @@ public class GreetingCrad implements Authorization{
@Test
(
description
=
"访客_礼物被领取完领取失败"
,
priority
=
35
)
@Test
(
description
=
"访客_礼物被领取完领取失败"
,
priority
=
35
)
public
void
访客
_
礼物被领取完领取失败
(){
public
void
访客
_
礼物被领取完领取失败
(){
//切换为访客
//切换为访客
userTku1
();
//
userTku1();
//查看阅读记录
//查看阅读记录
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
...
...
src/test/java/com/kjj/cases/assistant/whoSawMe/ForwardAndRead.java
View file @
5e6a7d12
...
@@ -24,7 +24,7 @@ public class ForwardAndRead implements Authorization {
...
@@ -24,7 +24,7 @@ public class ForwardAndRead implements Authorization {
@BeforeClass
@BeforeClass
public
void
setUp
()
throws
IOException
{
public
void
setUp
()
throws
IOException
{
agent
Tku
();
visitor2
Tku
();
BaseUtils
.
ssoLogin
();
BaseUtils
.
ssoLogin
();
}
}
...
@@ -58,8 +58,8 @@ public class ForwardAndRead implements Authorization {
...
@@ -58,8 +58,8 @@ public class ForwardAndRead implements Authorization {
// 访客访问素材及产生线索
// 访客访问素材及产生线索
@Test
(
description
=
"访客阅读文章"
,
priority
=
3
)
@Test
(
description
=
"访客阅读文章"
,
priority
=
3
)
public
void
访客阅读文章
()
throws
IOException
{
public
void
访客阅读文章
()
throws
IOException
{
sellerId
=
(
Long
)
getUserInfo
(
BasicConfig
.
AGENT
_TKU
).
get
(
"sellerId"
);
sellerId
=
(
Long
)
getUserInfo
(
BasicConfig
.
VISITOR2
_TKU
).
get
(
"sellerId"
);
network
.
agentCookies
.
put
(
"tku"
,
BasicConfig
.
VISITOR
_TKU
);
network
.
agentCookies
.
put
(
"tku"
,
BasicConfig
.
AGENT
_TKU
);
param
=
new
HashMap
<>();
param
=
new
HashMap
<>();
param
.
put
(
"scid"
,
articleScId
);
param
.
put
(
"scid"
,
articleScId
);
param
.
put
(
"fromUserId"
,
sellerId
);
param
.
put
(
"fromUserId"
,
sellerId
);
...
@@ -73,6 +73,8 @@ public class ForwardAndRead implements Authorization {
...
@@ -73,6 +73,8 @@ public class ForwardAndRead implements Authorization {
@Test
(
description
=
"访客领取赠险"
,
priority
=
4
)
@Test
(
description
=
"访客领取赠险"
,
priority
=
4
)
public
void
领取赠险
()
throws
IOException
{
public
void
领取赠险
()
throws
IOException
{
response
=
network
.
getResponse
(
BasicConfig
.
USER_INFO
);
System
.
out
.
println
(
response
.
body
().
asString
());
// 获取赠险insuranceId
// 获取赠险insuranceId
param
=
new
HashMap
<>();
param
=
new
HashMap
<>();
param
.
put
(
"scid"
,
articleScId
);
param
.
put
(
"scid"
,
articleScId
);
...
@@ -94,6 +96,16 @@ public class ForwardAndRead implements Authorization {
...
@@ -94,6 +96,16 @@ public class ForwardAndRead implements Authorization {
Assert
.
assertEquals
(
data
,
"success"
,
network
.
message
(
param
,
BasicConfig
.
SELLERCARD_SENDPUSHFORSCAN
,
"领取赠险失败"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
data
,
"success"
,
network
.
message
(
param
,
BasicConfig
.
SELLERCARD_SENDPUSHFORSCAN
,
"领取赠险失败"
,
response
.
body
().
asString
()));
}
}
// // 访客增加访问记录
// @Test(description = "增加动态访问记录", priority = 5)
// public void 增加动态访问记录() throws IOException{
// param = new HashMap<>();
// param.put("scid", articleScId);
// response = network.postResponse(param, BasicConfig.DYNAMIC_ADDVISIT);
// Assert.assertTrue(response.jsonPath().getBoolean("success"), network.message(param, BasicConfig.DYNAMIC_ADDVISIT, "接口请求失败", response.body().asString()));
// Assert.assertTrue(response.jsonPath().getBoolean("data"), network.message(param, BasicConfig.DYNAMIC_ADDVISIT, "增加访问记录失败", response.body().asString()));
// }
@Test
(
description
=
"访客转发文章"
,
priority
=
5
)
@Test
(
description
=
"访客转发文章"
,
priority
=
5
)
public
void
访客转发文章
()
throws
IOException
{
public
void
访客转发文章
()
throws
IOException
{
param
=
new
HashMap
<>();
param
=
new
HashMap
<>();
...
@@ -108,7 +120,7 @@ public class ForwardAndRead implements Authorization {
...
@@ -108,7 +120,7 @@ public class ForwardAndRead implements Authorization {
@Test
(
description
=
"二度访客阅读文章"
,
priority
=
6
)
@Test
(
description
=
"二度访客阅读文章"
,
priority
=
6
)
public
void
二度访客阅读文章
()
throws
IOException
{
public
void
二度访客阅读文章
()
throws
IOException
{
Long
fromUserId
=
decodeTku
(
BasicConfig
.
VISITOR
_TKU
).
get
(
"sellerId"
);
Long
fromUserId
=
decodeTku
(
BasicConfig
.
AGENT
_TKU
).
get
(
"sellerId"
);
network
.
agentCookies
.
put
(
"tku"
,
BasicConfig
.
VISITOR1_TKU
);
// 切换二度访客
network
.
agentCookies
.
put
(
"tku"
,
BasicConfig
.
VISITOR1_TKU
);
// 切换二度访客
param
=
new
HashMap
<>();
param
=
new
HashMap
<>();
param
.
put
(
"scid"
,
articleScId
);
param
.
put
(
"scid"
,
articleScId
);
...
@@ -158,7 +170,7 @@ public class ForwardAndRead implements Authorization {
...
@@ -158,7 +170,7 @@ public class ForwardAndRead implements Authorization {
infos
.
put
(
"wxName"
,
wxName
);
infos
.
put
(
"wxName"
,
wxName
);
infos
.
put
(
"sellerId"
,
sellerId
);
infos
.
put
(
"sellerId"
,
sellerId
);
infos
.
put
(
"userId"
,
userId
);
infos
.
put
(
"userId"
,
userId
);
network
.
agentCookies
.
put
(
"tku"
,
BasicConfig
.
AGENT
_TKU
);
network
.
agentCookies
.
put
(
"tku"
,
BasicConfig
.
VISITOR2
_TKU
);
return
infos
;
return
infos
;
}
}
...
...
src/test/java/com/kjj/cases/assistant/whoSawMe/MyCustomer.java
0 → 100644
View file @
5e6a7d12
This diff is collapsed.
Click to expand it.
src/test/java/com/kjj/cases/assistant/whoSawMe/MyForward.java
View file @
5e6a7d12
...
@@ -27,8 +27,7 @@ public class MyForward implements Authorization {
...
@@ -27,8 +27,7 @@ public class MyForward implements Authorization {
public
void
setUp
()
throws
IOException
{
public
void
setUp
()
throws
IOException
{
// 登陆管理后台
// 登陆管理后台
BaseUtils
.
ssoLogin
();
BaseUtils
.
ssoLogin
();
// 代理人授权
visitor2Tku
();
agentTku
();
far
=
new
ForwardAndRead
();
far
=
new
ForwardAndRead
();
// 关闭数据看板演示数据
// 关闭数据看板演示数据
...
@@ -237,7 +236,6 @@ public class MyForward implements Authorization {
...
@@ -237,7 +236,6 @@ public class MyForward implements Authorization {
param
.
put
(
"pageSize"
,
20
);
param
.
put
(
"pageSize"
,
20
);
param
.
put
(
"type"
,
4
);
param
.
put
(
"type"
,
4
);
response
=
network
.
getResponse
(
param
,
BasicConfig
.
FORWARD_VISITRECORD
);
response
=
network
.
getResponse
(
param
,
BasicConfig
.
FORWARD_VISITRECORD
);
System
.
out
.
println
(
response
.
body
().
asString
());
Assert
.
assertTrue
(
response
.
jsonPath
().
getBoolean
(
"success"
),
network
.
message
(
param
,
BasicConfig
.
FORWARD_VISITRECORD
,
"接口请求失败"
,
response
.
body
().
asString
()));
Assert
.
assertTrue
(
response
.
jsonPath
().
getBoolean
(
"success"
),
network
.
message
(
param
,
BasicConfig
.
FORWARD_VISITRECORD
,
"接口请求失败"
,
response
.
body
().
asString
()));
String
encodeUserId
=
response
.
jsonPath
().
getString
(
"data.list[0].userId"
);
String
encodeUserId
=
response
.
jsonPath
().
getString
(
"data.list[0].userId"
);
Assert
.
assertEquals
(
encodeUserId
,
far
.
encodeId
((
Long
)
far
.
getUserInfo
(
VISITOR1_TKU
).
get
(
"userId"
)),
network
.
message
(
param
,
FORWARD_VISITRECORD
,
"筛选结果首条记录userId与预期不符"
,
response
.
body
().
asString
()));
Assert
.
assertEquals
(
encodeUserId
,
far
.
encodeId
((
Long
)
far
.
getUserInfo
(
VISITOR1_TKU
).
get
(
"userId"
)),
network
.
message
(
param
,
FORWARD_VISITRECORD
,
"筛选结果首条记录userId与预期不符"
,
response
.
body
().
asString
()));
...
...
src/test/java/com/kjj/cases/assistant/whoSawMe/WhoSawMe.java
View file @
5e6a7d12
This diff is collapsed.
Click to expand it.
src/test/java/com/kjj/config/BasicConfig.java
View file @
5e6a7d12
...
@@ -74,6 +74,8 @@ public class BasicConfig {
...
@@ -74,6 +74,8 @@ public class BasicConfig {
public
static
String
VISITOR_TKU
=
"T3gM31f18jCGvqvoyJRzyMTdpcPDJWUJJP4VQje7p9sfC4HKmj5NJfCUkxusAyFb5SpkWS31srDTYr6KtV"
;
public
static
String
VISITOR_TKU
=
"T3gM31f18jCGvqvoyJRzyMTdpcPDJWUJJP4VQje7p9sfC4HKmj5NJfCUkxusAyFb5SpkWS31srDTYr6KtV"
;
// 基础线访客(小雪人) TKU
// 基础线访客(小雪人) TKU
public
static
String
VISITOR1_TKU
=
"T3gM31f18jCFXzk692pKjJCqJZdDv8Nb3htkzNk983cPMspUQD6pVEn2FNMefM2nieKPicXG9c1tDg8qtN"
;
public
static
String
VISITOR1_TKU
=
"T3gM31f18jCFXzk692pKjJCqJZdDv8Nb3htkzNk983cPMspUQD6pVEn2FNMefM2nieKPicXG9c1tDg8qtN"
;
// 基础线访客
public
static
String
VISITOR2_TKU
=
"T3gM31f18jCeKCBVHf5MANgyXeBZGCm8vTJQTuWYXHFqx97PATsWyUYamGaNdNip8bEs9shoE9tTsAmp8x"
;
// 二度访客用
// 访客的sids
// 访客的sids
public
static
final
String
sids
=
"Kj21MjMwNTU"
;
public
static
final
String
sids
=
"Kj21MjMwNTU"
;
// 访客(SuYi) userID:4425
// 访客(SuYi) userID:4425
...
@@ -231,6 +233,9 @@ public class BasicConfig {
...
@@ -231,6 +233,9 @@ public class BasicConfig {
public
static
final
String
MOBILE_result
=
MOBILE_HOST
+
"/clue/guess/number/red/result"
;
public
static
final
String
MOBILE_result
=
MOBILE_HOST
+
"/clue/guess/number/red/result"
;
public
static
final
String
MANAGER_encode
=
MANAGER_HOST
+
"/kjy/manager/testUser/encode"
;
// *************** 宝箱裂变 ***************
// *************** 宝箱裂变 ***************
public
static
final
String
MANAGER_getList4Admin
=
MANAGER_HOST
+
"/kjy/manager/welfare/pre/conf/getList4Admin"
;
public
static
final
String
MANAGER_getList4Admin
=
MANAGER_HOST
+
"/kjy/manager/welfare/pre/conf/getList4Admin"
;
public
static
final
String
MANAGER_saveTreasureConf
=
MANAGER_HOST
+
"/kjy/manager/live/treasure/saveTreasureConf"
;
public
static
final
String
MANAGER_saveTreasureConf
=
MANAGER_HOST
+
"/kjy/manager/live/treasure/saveTreasureConf"
;
...
@@ -684,6 +689,7 @@ public class BasicConfig {
...
@@ -684,6 +689,7 @@ public class BasicConfig {
// *************** 新手任务 ***************
// *************** 新手任务 ***************
public
static
final
String
NOVICE_LIST
=
HOST
+
"/kjy/mp/seller/novice/list"
;
public
static
final
String
NOVICE_LIST
=
HOST
+
"/kjy/mp/seller/novice/list"
;
public
static
final
String
NOVICE_MONGOLIANLAYERISPLAY
=
HOST
+
"/kjy/mp/seller/novice/mongolianLayerDisplay"
;
public
static
final
String
NOVICE_MONGOLIANLAYERISPLAY
=
HOST
+
"/kjy/mp/seller/novice/mongolianLayerDisplay"
;
public
static
final
String
COMPLETEGUIDE
=
HOST
+
"/kjy/mp/rookieGuide/completeGuide"
;
// *************** 谁看过我 ***************
// *************** 谁看过我 ***************
...
@@ -693,10 +699,34 @@ public class BasicConfig {
...
@@ -693,10 +699,34 @@ public class BasicConfig {
public
static
final
String
FORWARD_LIST
=
HOST
+
"/kjy/mp/whoSawMe/forward/list/v2"
;
public
static
final
String
FORWARD_LIST
=
HOST
+
"/kjy/mp/whoSawMe/forward/list/v2"
;
public
static
final
String
FORWARD_CONTENTHEADER
=
HOST
+
"/kjy/mp/whoSawMe/forward/contentHeader"
;
public
static
final
String
FORWARD_CONTENTHEADER
=
HOST
+
"/kjy/mp/whoSawMe/forward/contentHeader"
;
public
static
final
String
FORWARD_VISITRECORD
=
HOST
+
"/kjy/mp/whoSawMe/forward/visitRecordList/v2"
;
public
static
final
String
FORWARD_VISITRECORD
=
HOST
+
"/kjy/mp/whoSawMe/forward/visitRecordList/v2"
;
public
static
final
String
SELLERUNREADMESSAGE
=
HOST
+
"/kjy/mp/custmarketing/sellerUnreadMsg"
;
public
static
final
String
CUSTOMERSEARCH
=
HOST
+
"/kjy/mp/whoSawMe/customerSearch"
;
public
static
final
String
SEARCHCUSTOMERBYCONTENT
=
HOST
+
"/kjy/mp/custmarketing/searchCustomer"
;
public
static
final
String
DYNAMIC_ADDVISIT
=
HOST
+
"/kjy/mp/seller/dynamic/addVisit"
;
public
static
final
String
CLUEINFO
=
HOST
+
"/kjy/mp/whoSawMe/clue/info"
;
public
static
final
String
CLUEADVISE
=
HOST
+
"/kjy/mp/whoSawMe/clue/info/advise"
;
// *************** 客户信息 ***************
// *************** 客户信息 ***************
public
static
final
String
CUSTINFOHEADER
=
HOST
+
"/kjy/mp/whoSawMe/custInfoHeader"
;
public
static
final
String
CUSTINFO
=
HOST
+
"/kjy/mp/seller/v2/custInfo"
;
public
static
final
String
CLUESTATISTICS
=
HOST
+
"/kjy/mp/whoSawMe/clue/statistics"
;
public
static
final
String
CUSTRELATION
=
HOST
+
"/kjy/mp/seller/customer/relation"
;
public
static
final
String
CUSTOMERSTATISTICS
=
HOST
+
"/kjy/mp/whoSawMe/customerStatistics"
;
public
static
final
String
CUSTREADPERFERENCE
=
HOST
+
"/kjy/mp/seller/customer/getReadPerference"
;
public
static
final
String
CUSTSTATISTIC
=
HOST
+
"/kjy/mp/whoSawMe/customerInfo/statistic"
;
public
static
final
String
CUSTVISITLIST
=
HOST
+
"/kjy/mp/whoSawMe/customerInfo/list"
;
public
static
final
String
ISDISPLAYSPECIAL
=
HOST
+
"/kjy/mp/whoSawMe/isDisplaySpecialCustomerLayer"
;
public
static
final
String
CONTENTVISITRECORD
=
HOST
+
"/kjy/mp/whoSawMe/contentVisitRecord"
;
public
static
final
String
INVITATIONCHAIN
=
HOST
+
"/kjy/mp/whoSawMe/forward/forwardList"
;
public
static
final
String
INVITATIONCHAIN
=
HOST
+
"/kjy/mp/whoSawMe/forward/forwardList"
;
public
static
final
String
UPDATESPECIAL
=
HOST
+
"/kjy/mp/whoSawMe/updateSpecial"
;
public
static
final
String
totalSpecial
=
HOST
+
"/kjy/mp/whoSawMe/customerTotalStatistics"
;
public
static
final
String
UPDATEREMARKNAME
=
HOST
+
"/kjy/mp/seller/customer/updateRemarkName"
;
public
static
final
String
GETCUSTAGANDMEMO
=
HOST
+
"/kjy/mp/seller/getCustomerTagAndMemoInfo"
;
public
static
final
String
UPDATETAGANDMEMO
=
HOST
+
"/kjy/mp/seller/updateTagAndMemoInfo"
;
// *************** 标签管理 ***************
public
static
final
String
TAG_ADDORUPDATE
=
HOST
+
"/kjy/mp/sellerTag/addOrUpdateTag"
;
public
static
final
String
TAG_GETLIST
=
HOST
+
"/kjy/mp/sellerTag/getTagList"
;
public
static
final
String
TAG_DELETE
=
HOST
+
"/kjy/mp/sellerTag/deleteTag"
;
// *************** 文章 ***************
// *************** 文章 ***************
...
@@ -766,12 +796,24 @@ public class BasicConfig {
...
@@ -766,12 +796,24 @@ public class BasicConfig {
public
static
final
String
BOSS_CODE
=
HOST
+
"/kjy/mp/seller/team/invite/code"
;
public
static
final
String
BOSS_CODE
=
HOST
+
"/kjy/mp/seller/team/invite/code"
;
public
static
final
String
BOSS_BOSS
=
HOST
+
"/kjy/mp/seller/team/boss"
;
public
static
final
String
BOSS_BOSS
=
HOST
+
"/kjy/mp/seller/team/boss"
;
public
static
final
String
BOSS_EDITCONFIG
=
HOST
+
"/kjy/mp/sellerConfig/editConfig"
;
public
static
final
String
BOSS_EDITCONFIG
=
HOST
+
"/kjy/mp/sellerConfig/editConfig"
;
public
static
final
String
BOSS_ISDEMO
=
HOST
+
"/kjy/mp/seller/team/isDemo"
;
public
static
final
String
BOSS_TEAMTASKLIST
=
HOST
+
"/kjy/mp/seller/team/task/teamTaskList"
;
public
static
final
String
BOSS_CREATE
=
HOST
+
"/kjy/mp/seller/team/task/create"
;
public
static
final
String
BOSS_DETAIL
=
HOST
+
"/kjy/mp/seller/team/task/detail"
;
public
static
final
String
BOSS_PUBLISH
=
HOST
+
"/kjy/mp/seller/team/task/publish"
;
public
static
final
String
BOSS_RECEIVERLIST
=
HOST
+
"/kjy/mp/seller/team/task/receiverList"
;
public
static
final
String
BOSS_BOUND
=
HOST
+
"/kjy/mp/seller/team/bound"
;
public
static
final
String
BOSS_BOUND
=
HOST
+
"/kjy/mp/seller/team/bound"
;
public
static
final
String
MATERIALLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getMaterialList"
;
public
static
final
String
MATERIALLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getMaterialList"
;
public
static
final
String
FORWARDCARDLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getForwardCardList"
;
public
static
final
String
FORWARDCARDLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getForwardCardList"
;
public
static
final
String
MARKETINGTOOLLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getMarketingToolList"
;
public
static
final
String
MARKETINGTOOLLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getMarketingToolList"
;
public
static
final
String
SALECLUELIST
=
HOST
+
"/kjy/mp/seller/dynamic/getSaleClueList"
;
public
static
final
String
SALECLUELIST
=
HOST
+
"/kjy/mp/seller/dynamic/getSaleClueList"
;
public
static
final
String
GETVISITLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getVisitList"
;
public
static
final
String
GETVISITLIST
=
HOST
+
"/kjy/mp/seller/dynamic/getVisitList"
;
public
static
final
String
TEAMDATA
=
HOST
+
"/kjy/mp/seller/team/data"
;
public
static
final
String
TEAMMEMBERNUM
=
HOST
+
"/kjy/mp/seller/team/memberNumber"
;
public
static
final
String
TEAMRANKINGLIST
=
HOST
+
"/kjy/mp/seller/team/rankingList"
;
// 团队任务
public
static
final
String
FINDPAGEBYCONTENTTYPE
=
HOST
+
"/kjy/mp/exclusiveItem/findPageByContentType"
;
public
static
final
String
TEAMMEMBER
=
HOST
+
"/kjy/mp/seller/team/member"
;
...
@@ -842,7 +884,7 @@ public class BasicConfig {
...
@@ -842,7 +884,7 @@ public class BasicConfig {
public
static
final
String
MANAGER_findId
=
MANAGER_HOST
+
"/kjy/manager/dailyPosters/findById"
;
public
static
final
String
MANAGER_findId
=
MANAGER_HOST
+
"/kjy/manager/dailyPosters/findById"
;
public
static
final
String
MANAGER_addOrUpdate
=
MANAGER_HOST
+
"/kjy/manager/dailyPosters/addOrUpdate"
;
public
static
final
String
MANAGER_addOrUpdate
=
MANAGER_HOST
+
"/kjy/manager/dailyPosters/addOrUpdate"
;
public
static
final
String
MANAGER_dailyPostersDelete
=
MANAGER_HOST
+
"/kjy/manager/dailyPosters/delete"
;
public
static
final
String
MANAGER_dailyPostersDelete
=
MANAGER_HOST
+
"/kjy/manager/dailyPosters/delete"
;
public
static
final
String
MANAGER_
removeMember
=
MANAGER_HOST
+
"/kjy/manager/sellerTeam/removeMember"
;
public
static
final
String
MANAGER_
SELLERTEAM_REMOVEMEMBER
=
MANAGER_HOST
+
"/kjy/manager/sellerTeam/removeMember"
;
public
static
final
String
MANAGER_ID_ENCODE
=
MANAGER_HOST
+
"/kjy/manager/testUser/encode"
;
public
static
final
String
MANAGER_ID_ENCODE
=
MANAGER_HOST
+
"/kjy/manager/testUser/encode"
;
public
static
final
String
MANAGER_TKU_DECODE
=
MANAGER_HOST
+
"/kjy/manager/testUser/decryptTku"
;
public
static
final
String
MANAGER_TKU_DECODE
=
MANAGER_HOST
+
"/kjy/manager/testUser/decryptTku"
;
public
static
final
String
MANAGER_searchTemplateList
=
MANAGER_HOST
+
"/kjy/manager/game/searchTemplateList"
;
public
static
final
String
MANAGER_searchTemplateList
=
MANAGER_HOST
+
"/kjy/manager/game/searchTemplateList"
;
...
...
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