Commit dfd9db78 authored by 张艳玲's avatar 张艳玲

update

parent bd96bb49
...@@ -35,7 +35,7 @@ public class OpenLive implements AdminAuthorization { ...@@ -35,7 +35,7 @@ public class OpenLive implements AdminAuthorization {
Object data = openRes.jsonPath().getJsonObject("data"); Object data = openRes.jsonPath().getJsonObject("data");
System.out.println(data); System.out.println(data);
Assert.assertNotNull(data, network.message(openParam, BasicConfig.ANCHOR_OPEN, "开启直播失败", openRes.body().asString())); Assert.assertNotNull(data, network.message(openParam, BasicConfig.ANCHOR_OPEN, "开启直播失败", openRes.body().asString()));
ThreadSleepUtils.sleep(10000); ThreadSleepUtils.sleep(5000);
} }
......
...@@ -288,10 +288,13 @@ public class Lottery implements AdminAuthorization { ...@@ -288,10 +288,13 @@ public class Lottery implements AdminAuthorization {
Map<String, Object> luckDetailParam = new HashMap<>(); Map<String, Object> luckDetailParam = new HashMap<>();
luckDetailParam.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey())); luckDetailParam.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey()));
Response luckDetailRes = network.getResponse(luckDetailParam, BasicConfig.ANCHOR_luckDetail); Response luckDetailRes = network.getResponse(luckDetailParam, BasicConfig.ANCHOR_luckDetail);
Object data = luckDetailRes.jsonPath().getJsonObject("data"); try {
System.out.println(data); Boolean hasDrawTask = luckDetailRes.jsonPath().getBoolean("data.hasDrawTask");
Assert.assertNotNull(data, network.message(luckDetailParam, BasicConfig.ANCHOR_luckDetail, "查询中奖任务失败", luckDetailRes.body().asString())); Assert.assertTrue(hasDrawTask, network.message(luckDetailParam, BasicConfig.USER_result, "查询中奖任务失败", luckDetailRes.body().asString()));
} catch (Exception e) {
System.out.println("result = " + JSON.toJSONString(luckDetailRes.jsonPath().get()));
throw e;
}
} }
@Test(description = "访客A中奖任务_分享直播间", priority = 21) @Test(description = "访客A中奖任务_分享直播间", priority = 21)
...@@ -428,7 +431,7 @@ public class Lottery implements AdminAuthorization { ...@@ -428,7 +431,7 @@ public class Lottery implements AdminAuthorization {
break; break;
} }
} }
Assert.assertNotNull(result, network.message(myLotteryCodeParam, BasicConfig.MOBILE_MyLotteryCode, "查询访客A抽奖券列表失败", myLotteryCodeRes.body().asString())); Assert.assertTrue(result, network.message(myLotteryCodeParam, BasicConfig.MOBILE_MyLotteryCode, "查询访客A抽奖券列表失败", myLotteryCodeRes.body().asString()));
} }
@Test(description = "访客A抽奖码数量", priority = 31) @Test(description = "访客A抽奖码数量", priority = 31)
...@@ -451,9 +454,13 @@ public class Lottery implements AdminAuthorization { ...@@ -451,9 +454,13 @@ public class Lottery implements AdminAuthorization {
Map<String, Object> luckDetailParam = new HashMap<>(); Map<String, Object> luckDetailParam = new HashMap<>();
luckDetailParam.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey())); luckDetailParam.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey()));
Response luckDetailRes = network.getResponse(luckDetailParam, BasicConfig.ANCHOR_luckDetail); Response luckDetailRes = network.getResponse(luckDetailParam, BasicConfig.ANCHOR_luckDetail);
Object data = luckDetailRes.jsonPath().getJsonObject("data"); try {
System.out.println(data); Boolean hasLuckTask = luckDetailRes.jsonPath().getBoolean("data.hasLuckTask");
Assert.assertNotNull(data, network.message(luckDetailParam, BasicConfig.ANCHOR_luckDetail, "查询中奖任务失败", luckDetailRes.body().asString())); Assert.assertTrue(hasLuckTask, network.message(luckDetailParam, BasicConfig.USER_result, "查询任务失败", luckDetailRes.body().asString()));
} catch (Exception e) {
System.out.println("result = " + JSON.toJSONString(luckDetailRes.jsonPath().get()));
throw e;
}
} }
...@@ -609,7 +616,7 @@ public class Lottery implements AdminAuthorization { ...@@ -609,7 +616,7 @@ public class Lottery implements AdminAuthorization {
@Test(description = "访客B的抽奖券列表", priority = 44) @Test(description = "访客B的抽奖券列表", priority = 44)
public void 访客B的抽奖券列表() { public void 访客B的抽奖券列表() {
visitorAuth2(); visitorAuth2();
ThreadSleepUtils.sleep(10000); ThreadSleepUtils.sleep(3000);
Map<String, Object> myLotteryCodeParam = new HashMap<>(); Map<String, Object> myLotteryCodeParam = new HashMap<>();
myLotteryCodeParam.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey())); myLotteryCodeParam.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey()));
myLotteryCodeParam.put("pageIndex", 1); myLotteryCodeParam.put("pageIndex", 1);
......
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