Commit 7df23e56 authored by 郭姣's avatar 郭姣

Merge branch 'master' into gifeature/20211209-gj

parents dc0f0f59 d4f81d9b
......@@ -293,13 +293,4 @@ public class Cashback implements Authorization {
Assert.assertTrue(changeMoney1 ==35.0, network.message(PAY_accDetail, "一级付费普通代理人返现金额不为35", response.body().asString()));
}
@Test(description = "删除邀请关系",priority = 15)
public void 删除邀请关系() {
Map<String, Object> Params = new HashMap<>();
Params.put("sellerId", 186);
Response response = network.postResponse(Params, PAY_delete);
boolean data = response.jsonPath().getBoolean("data");
Assert.assertTrue(data, network.message(PAY_delete, "删除失败", response.body().asString()));
}
}
......@@ -6,6 +6,7 @@ import com.kjj.cases.live.anchor.LiveVisitors;
import com.kjj.cases.live.lottery.Lottery;
import com.kjj.config.BasicConfig;
import com.kjj.constants.LiveConstants;
import com.kjj.utils.IdMakeUtil;
import io.restassured.response.Response;
import org.testng.Assert;
import org.testng.annotations.BeforeClass;
......@@ -14,19 +15,22 @@ import org.testng.collections.Lists;
import java.util.*;
import static com.kjj.utils.ThreadSleepUtils.sleep;
public class AfterLive implements Authorization {
private Map<String, Object> params;
private String encodeLiveId;
@BeforeClass
public void SetUp(){ visitorAuth1(); }
public void SetUp(){
visitorAuth1();
params = new HashMap<>();}
// 获取访客直播结束页样式
@Test(description = "获取访客直播结束页样式", priority = 1)
public void 获取访客直播结束页样式(){
encodeLiveId = LiveConstants.getValue(LiveConstants.StringKeyEnum.ENCODE_LIVE_ID.getKey()); // 获取直播ID
params = new HashMap<>();
params.put("liveId", encodeLiveId);
Response response = network.getResponse(params, BasicConfig.USER_liveEnd);
Assert.assertTrue(response.jsonPath().getBoolean("success"), network.message(params, BasicConfig.USER_liveEnd, "接口调用失败", response.body().asString()));
......@@ -55,7 +59,10 @@ public class AfterLive implements Authorization {
Response response = network.getResponse(params, BasicConfig.USER_getAgentQrCode);
Assert.assertTrue(response.jsonPath().getBoolean("success"), network.message(params, BasicConfig.USER_getAgentQrCode, "接口请求失败", response.body().asString()));
int pollingResult = response.jsonPath().getInt("data.pollingResult");
while (pollingResult == 2){
int i = 0;
while (pollingResult == 2&& i != 10){
i++;
sleep(1000);
response = network.getResponse(params, BasicConfig.USER_getAgentQrCode);
pollingResult = response.jsonPath().getInt("data.pollingResult");
}
......
......@@ -803,7 +803,6 @@ public class BasicConfig {
public static final String PAY_popup = HOST + "/kjj/vip/order/other/popup";
public static final String PAY_distribute = HOST + "/kjj/auto/test/proCode/distribute";
public static final String PAY_bind = HOST + "/kjj/auto/test/invitation/bind";
public static final String PAY_delete = HOST + "/kjj/auto/test/invitation/delete";
// *************** 名片 ***************
public static final String SELLERCARD_topOfDetail = HOST + "/kjy/mp/sellerCardV5/topOfDetail";
......
......@@ -23,17 +23,19 @@ public class DingTalkUtils {
//测试结果
context = "【接口自动化测试结果反馈】\n"
+ context
+ "报告地址: http://10.172.58.199/view/kkk/job/kejiji_interface/HTML_20Report\n"
+ "@龚小红";
+ "报告地址: http://10.172.58.199/view/kkk/job/kejiji_interface/HTML_20Report\n";
System.out.println(context);
Map<String, Object> contentParams = new HashMap<String, Object>();
contentParams.put("content",context);
Map<String, Object> atParams = new HashMap<String, Object>();
atParams.put("atMobiles","17830855590");
//钉钉机器人消息体
Map<String, Object> params = new HashMap<String, Object>();
params.put("msgtype","text");
params.put("text",contentParams);
params.put("at", atParams);
//发起dingding机器人通知
if (isPushReport){
......
......@@ -101,6 +101,7 @@
<class name="com.kjj.cases.assistant.enterpriseAgent.EnterpriseAgent"/>
</classes>
</test>
</suite>
<!-- Suite -->
......
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