Commit 511673dd authored by 龚小红's avatar 龚小红

修改用例名称

parent 956c7eb1
...@@ -316,8 +316,8 @@ public class Lottery implements Authorization { ...@@ -316,8 +316,8 @@ public class Lottery implements Authorization {
} }
@Test(description = "访客B获取好运红包领取记录", priority = 28) @Test(description = "访客M获取好运红包领取", priority = 28)
public void 访客B获取好运红包领取记录() { public void 访客M获取好运红包领取() {
visitorAuth13(); visitorAuth13();
ThreadSleepUtils.sleep(2000); ThreadSleepUtils.sleep(2000);
Map<String, Object> Params = new HashMap<>(); Map<String, Object> Params = new HashMap<>();
...@@ -333,12 +333,12 @@ public class Lottery implements Authorization { ...@@ -333,12 +333,12 @@ public class Lottery implements Authorization {
response = network.getResponse(Params, BasicConfig.MOBILE_receiveRecord); response = network.getResponse(Params, BasicConfig.MOBILE_receiveRecord);
System.out.println( response.body().asString()); System.out.println( response.body().asString());
Object data = response.jsonPath().getJsonObject("data"); Object data = response.jsonPath().getJsonObject("data");
Assert.assertNull(data, network.message(Params, BasicConfig.MOBILE_receiveRecord, "访客B获取好运红包领取记录不为空", response.body().asString())); Assert.assertNull(data, network.message(Params, BasicConfig.MOBILE_receiveRecord, "访客M获取好运红包领取记录为空", response.body().asString()));
} }
@Test(description = "访客B领取好运红包", priority = 29) @Test(description = "访客M领取好运红包", priority = 29)
public void 访客B领取好运红包() { public void 访客M领取好运红包() {
visitorAuth13(); visitorAuth13();
Map<String, Object> Params = new HashMap<>(); Map<String, Object> Params = new HashMap<>();
Params.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey())); Params.put("liveId", LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey()));
...@@ -346,12 +346,12 @@ public class Lottery implements Authorization { ...@@ -346,12 +346,12 @@ public class Lottery implements Authorization {
Response response = network.postResponse(Params, BasicConfig.MOBILE_receiverOpen); Response response = network.postResponse(Params, BasicConfig.MOBILE_receiverOpen);
System.out.println( response.body().asString()); System.out.println( response.body().asString());
boolean data = response.jsonPath().getBoolean("data"); boolean data = response.jsonPath().getBoolean("data");
Assert.assertTrue(data, network.message(Params, BasicConfig.MOBILE_receiverOpen, "访客B领取好运红包失败", response.body().asString())); Assert.assertTrue(data, network.message(Params, BasicConfig.MOBILE_receiverOpen, "访客M领取好运红包失败", response.body().asString()));
} }
@Test(description = "访客B参与记录", priority = 30) @Test(description = "访客M参与记录", priority = 30)
public void 访客B参与记录() { public void 访客M参与记录() {
visitorAuth13(); visitorAuth13();
ThreadSleepUtils.sleep(3000); ThreadSleepUtils.sleep(3000);
Map<String, Object> Params = new HashMap<>(); Map<String, Object> Params = new HashMap<>();
...@@ -368,8 +368,8 @@ public class Lottery implements Authorization { ...@@ -368,8 +368,8 @@ public class Lottery implements Authorization {
} }
@Test(description = "访客A获取好运红包领取记录", priority = 31) @Test(description = "访客M获取好运红包领取记录", priority = 31)
public void 访客A获取好运红包领取记录() { public void 访客M获取好运红包领取记录() {
visitorAuth13(); visitorAuth13();
ThreadSleepUtils.sleep(500); ThreadSleepUtils.sleep(500);
Map<String, Object> Params = new HashMap<>(); Map<String, Object> Params = new HashMap<>();
...@@ -1206,7 +1206,7 @@ public class Lottery implements Authorization { ...@@ -1206,7 +1206,7 @@ public class Lottery implements Authorization {
Response hasEndResB = network.getResponse(hasEndParam, BasicConfig.USER_result); Response hasEndResB = network.getResponse(hasEndParam, BasicConfig.USER_result);
boolean dataB = getDataLottery(hasEndResB); boolean dataB = getDataLottery(hasEndResB);
String responseBody = "A=" + hasEndResA.body().asString() + ", B=" + hasEndResB.body().asString(); String responseBody = "A=" + hasEndResA.body().asString() + ", B=" + hasEndResB.body().asString();
Assert.assertTrue(dataA && dataB && dataC, network.message(hasEndParam, BasicConfig.USER_result, "访客未中奖", responseBody)); Assert.assertTrue(dataA || dataB || dataC, network.message(hasEndParam, BasicConfig.USER_result, "访客未中奖", responseBody));
} }
......
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