Commit cf2f8d6f authored by 马博's avatar 马博

Merge remote-tracking branch 'origin/mabo' into mabo

parents 07a37391 b4306a2d
...@@ -33,7 +33,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase { ...@@ -33,7 +33,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase {
public void 出奖自有实物() throws Exception { public void 出奖自有实物() throws Exception {
Map map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900849714500524"); Map map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900849714500524");
long remaining = (long)map.get("stock"); int remaining = (int)map.get("stock");
Response response = newActivityService.doJoin2("21803","h5ps61"); Response response = newActivityService.doJoin2("21803","h5ps61");
String orderId = response.jsonPath().getString("orderId"); String orderId = response.jsonPath().getString("orderId");
response = newActivityService.getOrderStatus2(orderId); response = newActivityService.getOrderStatus2(orderId);
...@@ -61,7 +61,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase { ...@@ -61,7 +61,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase {
Thread.sleep(1000); Thread.sleep(1000);
map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900849714500524"); map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900849714500524");
long remainingNew = (long)map.get("stock"); int remainingNew = (int)map.get("stock");
Assert.assertEquals(remaining-1,remainingNew,"扣库存失败"); Assert.assertEquals(remaining-1,remainingNew,"扣库存失败");
...@@ -170,7 +170,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase { ...@@ -170,7 +170,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase {
public void 出奖自有虚拟商品() throws Exception { public void 出奖自有虚拟商品() throws Exception {
Map map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900860200070105"); Map map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900860200070105");
long remaining = (long)map.get("stock"); int remaining = (int)map.get("stock");
Response response = newActivityService.doJoin2("21793","h5ps61"); Response response = newActivityService.doJoin2("21793","h5ps61");
String orderId = response.jsonPath().getString("orderId"); String orderId = response.jsonPath().getString("orderId");
response = newActivityService.getOrderStatus2(orderId); response = newActivityService.getOrderStatus2(orderId);
...@@ -198,7 +198,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase { ...@@ -198,7 +198,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase {
Thread.sleep(1000); Thread.sleep(1000);
map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900860200070105"); map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900860200070105");
long remainingNew = (long)map.get("stock"); int remainingNew = (int)map.get("stock");
Assert.assertEquals(remaining-1,remainingNew,"扣库存失败"); Assert.assertEquals(remaining-1,remainingNew,"扣库存失败");
} }
...@@ -206,7 +206,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase { ...@@ -206,7 +206,7 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase {
@Test @Test
public void 出奖兑吧实物() throws Exception { public void 出奖兑吧实物() throws Exception {
Map map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900440770170322 "); Map map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900440770170322 ");
long remaining = (long)map.get("stock"); int remaining = (int)map.get("stock");
Response response = newActivityService.doJoin2("22637","h5ps61"); Response response = newActivityService.doJoin2("22637","h5ps61");
String orderId = response.jsonPath().getString("orderId"); String orderId = response.jsonPath().getString("orderId");
response = newActivityService.getOrderStatus2(orderId); response = newActivityService.getOrderStatus2(orderId);
...@@ -233,12 +233,10 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase { ...@@ -233,12 +233,10 @@ public class 自有活动出奖_DuibaTest extends DuibaTestBase {
Thread.sleep(1000); Thread.sleep(1000);
map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900440770170322 "); map = jdbc.findSimpleResult("select * from stock.tb_stock where stock_id = 674900440770170322 ");
long remainingNew = (long)map.get("stock"); int remainingNew = (int)map.get("stock");
Assert.assertEquals(remaining-1,remainingNew,"扣库存失败"); Assert.assertEquals(remaining-1,remainingNew,"扣库存失败");
} }
@Test @Test
......
...@@ -449,19 +449,18 @@ public class 兑吧新实物_兑换流程测试_ExchangeTest extends CheckTemple ...@@ -449,19 +449,18 @@ public class 兑吧新实物_兑换流程测试_ExchangeTest extends CheckTemple
@Test(description = "新实物确认下单页面") @Test(description = "新实物确认下单页面")
public void 实物确认下单测试() throws Exception{ public void 实物确认下单测试() throws Exception{
int uid = 7284; String appItemId = "196218";
String appItemId = "196093"; String appSkuId = "145";
String appSkuId = "154";
Response response = gawService.confirmItemDetail(uid,appItemId,appSkuId); Response response = gawService.confirmItemDetail(uid,appItemId,appSkuId);
response.prettyPrint(); response.prettyPrint();
Assert.assertEquals(response.jsonPath().getString("data.items[0].sku.attr[0].value"),"白色","校验sku信息颜色失败"); Assert.assertEquals(response.jsonPath().getString("data.items[0].sku.attr[0].value"),"白色","校验sku信息颜色失败");
Assert.assertEquals(response.jsonPath().getString("data.items[0].sku.attr[1].value"),"S","校验sku信息尺寸失败"); Assert.assertEquals(response.jsonPath().getString("data.items[0].sku.attr[1].value"),"S","校验sku信息尺寸失败");
Assert.assertEquals(response.jsonPath().getString("data.items[0].sku.credits"),"200","校验sku商品积分失败"); Assert.assertEquals(response.jsonPath().getString("data.items[0].sku.credits"),"100","校验sku商品积分失败");
Assert.assertEquals(response.jsonPath().getString("data.items[0].multiImage"),"//yun.dui88.com/images/201905/h8x0e1talx.png","校验图片信息失败"); Assert.assertEquals(response.jsonPath().getString("data.items[0].multiImage"),"//yun.dui88.com/images/201906/9p72lmu1qn.jpg","校验图片信息失败");
Assert.assertEquals(response.jsonPath().getString("data.items[0].title"),"【自动化勿动】自有实物sku","校验实物名称失败"); Assert.assertEquals(response.jsonPath().getString("data.items[0].title"),"【自动化勿动】自有实物sku","校验实物名称失败");
Assert.assertEquals(response.jsonPath().getString("data.orderCredits"),"200","校验订单积分失败"); Assert.assertEquals(response.jsonPath().getString("data.orderCredits"),"100","校验订单积分失败");
Assert.assertEquals(response.jsonPath().getString("data.expressPrice"),"500","校验订单运费金额失败"); Assert.assertEquals(response.jsonPath().getString("data.expressPrice"),"500","校验订单运费金额失败");
Assert.assertEquals(response.jsonPath().getString("data.consumerPayPrice"),"500","校验订单支付金额失败"); Assert.assertEquals(response.jsonPath().getString("data.consumerPayPrice"),"500","校验订单支付金额失败");
...@@ -475,4 +474,5 @@ public class 兑吧新实物_兑换流程测试_ExchangeTest extends CheckTemple ...@@ -475,4 +474,5 @@ public class 兑吧新实物_兑换流程测试_ExchangeTest extends CheckTemple
} }
...@@ -42,7 +42,6 @@ public class 自有新实物_兑换流程测试_ExchangeTest extends CheckTemple ...@@ -42,7 +42,6 @@ public class 自有新实物_兑换流程测试_ExchangeTest extends CheckTemple
return result; return result;
} }
@BeforeMethod @BeforeMethod
public void beforeMethod(){ public void beforeMethod(){
try { try {
...@@ -379,6 +378,8 @@ public class 自有新实物_兑换流程测试_ExchangeTest extends CheckTemple ...@@ -379,6 +378,8 @@ public class 自有新实物_兑换流程测试_ExchangeTest extends CheckTemple
} }
//测试使用
//@Test(enabled=true, dataProvider="testdp", threadPoolSize=1, invocationCount=100)
@DataProvider(name = "testdp", parallel = true) @DataProvider(name = "testdp", parallel = true)
public static Object[][]testdp(){ public static Object[][]testdp(){
return new Object[][]{ return new Object[][]{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment