Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tiku_APP_APITest
Overview
Overview
Details
Activity
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
shuai
tiku_APP_APITest
Commits
0653b1fd
Commit
0653b1fd
authored
Jun 21, 2019
by
Li Yongyu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
8b6cf330
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
5 deletions
+11
-5
RequestDataUtils.java
tiku_App/src/com/offcn/TestUnti/RequestDataUtils.java
+2
-1
getRecommend.java
tiku_App/src/com/offcn/api/tk/app3/getRecommend.java
+9
-4
No files found.
tiku_App/src/com/offcn/TestUnti/RequestDataUtils.java
View file @
0653b1fd
...
...
@@ -195,7 +195,8 @@ public class RequestDataUtils {
try
{
state
++;
re
=
jobApi
(
data
,
myRequest
)
.
contentType
(
JSON
).
body
(
"{"
+
Parameter
+
"}"
).
when
()
.
contentType
(
JSON
)
.
body
(
"{"
+
Parameter
+
"}"
).
when
()
.
post
(
myRequest
.
getUrl
()).
thenReturn
();
if
(!
"200"
.
equals
(
re
.
getStatusCode
()+
""
))
{
Log
.
logError
(
"请求返回,"
+
re
.
getStatusCode
()
+
"次。"
);
...
...
tiku_App/src/com/offcn/api/tk/app3/getRecommend.java
View file @
0653b1fd
...
...
@@ -85,9 +85,14 @@ public class getRecommend extends TK implements API {
JsonPath
jp
=
re
.
body
().
jsonPath
();
boolean
result
=
true
;
String
failReason
=
""
;
/*System.out.println("getContentType=====" + re.getContentType());
System.out.println("getHeaders====="+re.getHeaders());
System.out.println(re.getSessionId());;
System.out.println(re.statusCode());*/
String
json
=
StringUtils
.
decodeUnicode
(
re
.
asString
());
//System.out.println("re======"+ json);
if
((
data
.
get
(
"statusCode"
)
!=
null
)
&&
(!
data
.
get
(
"statusCode"
).
toString
()
.
equals
(
String
.
valueOf
(
re
.
getStatusCode
()))))
{
...
...
@@ -142,8 +147,8 @@ public class getRecommend extends TK implements API {
}
if
(
"0"
.
equals
(
code
)){
/*L_record_sub_id=jp.getString("data.record_sub_id"
);
L_mock_subject_id=jp.getString("data.mock_subject_id");*/
System
.
out
.
println
(
"data.recommend[0]====="
+
jp
.
getString
(
"data.recommend[0].id"
)
);
System
.
out
.
println
(
"data.recommend[1]====="
+
jp
.
getString
(
"data.recommend[1].id"
));
}
}
if
(
result
)
...
...
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