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
8cd685e7
Commit
8cd685e7
authored
Mar 25, 2021
by
张艳玲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
e8ea1d47
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
25 deletions
+23
-25
Boss.java
src/test/java/com/kjj/cases/basics/Boss.java
+18
-20
wechatTestNG.xml
src/test/wechatTestNG.xml
+5
-5
No files found.
src/test/java/com/kjj/cases/basics/Boss.java
View file @
8cd685e7
...
...
@@ -90,26 +90,24 @@ public class Boss {
Assert.assertNotNull(visitorName,network.message(USER_INFO,"获取sellerName失败",response.body().asString()));
}*/
//邀请结果判断
@Test
(
description
=
"邀请结果"
,
priority
=
7
)
public
void
邀请结果
()
throws
IOException
{
Map
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
params
.
put
(
"inviterSid"
,
sellerId
);
params
.
put
(
"inviteType"
,
2
);
network
.
agentCookies
.
put
(
"tku"
,
VISITOR_TKU
);
Response
response
=
network
.
getResponse
(
params
,
BOSS_BOUND
);
boolean
data
=
true
;
// response.jsonPath().getBoolean("data"); //1 true:邀请成功;2 false:邀请失败
Assert
.
assertTrue
(
data
,
network
.
message
(
params
,
BOSS_BOUND
,
"接受邀请失败"
,
response
.
body
().
asString
()));
//获取被邀请人上级昵称
Map
<
String
,
Object
>
inviteparams
=
new
HashMap
<
String
,
Object
>();
params
.
put
(
"sellerId"
,
vistorId
);
Response
responses
=
network
.
getResponse
(
inviteparams
,
BOSS_BOSS
);
String
name
=
responses
.
jsonPath
().
getString
(
"data"
);
Assert
.
assertEquals
(
name
,
sellerName
,
network
.
message
(
params
,
BOSS_BOSS
,
"昵称不匹配"
,
response
.
body
().
asString
()));
}
// //邀请结果判断
// @Test(description="邀请结果",priority = 7)
// public void 邀请结果() throws IOException{
// Map<String, Object> params = new HashMap<String, Object>();
// params.put("inviterSid",sellerId);
// params.put("inviteType",2);
// network.agentCookies.put("tku",VISITOR_TKU);
// Response response = network.getResponse(params,BOSS_BOUND);
// boolean data =true;// response.jsonPath().getBoolean("data"); //1 true:邀请成功;2 false:邀请失败
// Assert.assertTrue(data, network.message(params,BOSS_BOUND,"接受邀请失败",response.body().asString()));
// //获取被邀请人上级昵称
// Map<String, Object> inviteparams = new HashMap<String, Object>();
// params.put("sellerId",vistorId);
// Response responses = network.getResponse(inviteparams,BOSS_BOSS);
// String name = responses.jsonPath().getString("data");
// Assert.assertEquals(name,sellerName,network.message(params,BOSS_BOSS,"昵称不匹配",response.body().asString()));
// }
//重新获取列表,代理人有无上下级判断;
@Test
(
description
=
"当前代理人角色二次判断"
,
priority
=
8
)
...
...
src/test/wechatTestNG.xml
View file @
8cd685e7
...
...
@@ -46,11 +46,11 @@
<class
name=
"com.kjj.cases.basics.BossTest"
/>
</classes>
</test>
<!-- <test preserve-order="true" name="贺卡">--
>
<!-- <classes>--
>
<!-- <class name="com.kjj.cases.basics.GreetingCard"/>--
>
<!-- </classes>--
>
<!-- </test>--
>
<test
preserve-order=
"true"
name=
"贺卡"
>
<classes
>
<class
name=
"com.kjj.cases.basics.GreetingCard"
/
>
</classes
>
</test
>
</suite>
<!-- Suite -->
...
...
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