Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
test-platform
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
马博
test-platform
Commits
6de6baa0
Commit
6de6baa0
authored
Jul 02, 2020
by
吕雯燕
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lv
parent
2d8f4211
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
平台券_兑换流程测试_ExchangeTest.java
...java/http/cases/ExchangeTest/平台券_兑换流程测试_ExchangeTest.java
+3
-3
No files found.
src/test/java/http/cases/ExchangeTest/平台券_兑换流程测试_ExchangeTest.java
View file @
6de6baa0
...
@@ -85,7 +85,7 @@ public class 平台券_兑换流程测试_ExchangeTest extends CheckTemplet {
...
@@ -85,7 +85,7 @@ public class 平台券_兑换流程测试_ExchangeTest extends CheckTemplet {
public
void
平台券扣积分和库存测试
()
throws
Exception
{
public
void
平台券扣积分和库存测试
()
throws
Exception
{
//查询平台券兑换前的库存和积分
//查询平台券兑换前的库存和积分
Map
<
String
,
Object
>
mapStock
=
jdbc
.
findSimpleResult
(
"SELECT * FROM stock.tb_stock WHERE stock_id =
73725312477067
0925"
);
Map
<
String
,
Object
>
mapStock
=
jdbc
.
findSimpleResult
(
"SELECT * FROM stock.tb_stock WHERE stock_id =
129532253408842
0925"
);
String
stock
=
String
.
valueOf
(
mapStock
.
get
(
"stock"
))
;
String
stock
=
String
.
valueOf
(
mapStock
.
get
(
"stock"
))
;
logger
.
info
(
"兑换前的平台券库存:"
+
stock
);
logger
.
info
(
"兑换前的平台券库存:"
+
stock
);
stock
=
String
.
valueOf
(
Integer
.
parseInt
(
stock
)
-
1
)
;
stock
=
String
.
valueOf
(
Integer
.
parseInt
(
stock
)
-
1
)
;
...
@@ -100,7 +100,7 @@ public class 平台券_兑换流程测试_ExchangeTest extends CheckTemplet {
...
@@ -100,7 +100,7 @@ public class 平台券_兑换流程测试_ExchangeTest extends CheckTemplet {
logger
.
info
(
"订单号:"
+
orderId
);
logger
.
info
(
"订单号:"
+
orderId
);
//查询优惠券兑换后的库存和积分
//查询优惠券兑换后的库存和积分
mapStock
=
jdbc
.
findSimpleResult
(
"SELECT * FROM stock.tb_stock WHERE stock_id =
73725312477067
0925"
);
mapStock
=
jdbc
.
findSimpleResult
(
"SELECT * FROM stock.tb_stock WHERE stock_id =
129532253408842
0925"
);
String
stockNew
=
String
.
valueOf
(
mapStock
.
get
(
"stock"
))
;
String
stockNew
=
String
.
valueOf
(
mapStock
.
get
(
"stock"
))
;
logger
.
info
(
"兑换后的优惠券库存:"
+
stockNew
);
logger
.
info
(
"兑换后的优惠券库存:"
+
stockNew
);
...
@@ -285,7 +285,7 @@ public class 平台券_兑换流程测试_ExchangeTest extends CheckTemplet {
...
@@ -285,7 +285,7 @@ public class 平台券_兑换流程测试_ExchangeTest extends CheckTemplet {
map
.
put
(
"pcgId"
,
"74371944595109"
);
map
.
put
(
"pcgId"
,
"74371944595109"
);
map
.
put
(
"token"
,
"yrJRr7Cddp2YeQd"
);
map
.
put
(
"token"
,
"yrJRr7Cddp2YeQd"
);
//获取按钮状态
//获取按钮状态
【
Response
detailResponse
=
appPlatformCouponService
.
platformDetail
(
uid
,
"74371944595109"
);
Response
detailResponse
=
appPlatformCouponService
.
platformDetail
(
uid
,
"74371944595109"
);
detailResponse
.
prettyPrint
();
detailResponse
.
prettyPrint
();
String
exchangeText
=
MatcherString
.
getString
(
detailResponse
.
asString
(),
"exchangeText: '(.*?)',"
,
1
);
String
exchangeText
=
MatcherString
.
getString
(
detailResponse
.
asString
(),
"exchangeText: '(.*?)',"
,
1
);
...
...
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