Commit 0994ac80 authored by 赵然's avatar 赵然

zr

parent fd64fe09
......@@ -25,7 +25,7 @@ import static io.restassured.RestAssured.given;
* Created by 赵然 on 2019/04/04
* AppId: 22565
*/
public class 总帐户提现页校验 extends DuibaTestBase{
public class 总帐户提现页校验_AccessTest extends DuibaTestBase{
@Value("${activity.host}")
String activityHost;
@Autowired
......@@ -83,5 +83,8 @@ public class 总帐户提现页校验 extends DuibaTestBase{
Assert.assertEquals(relType,"PK","关联活动类型校验失败");
Assert.assertEquals(relTypeName,"组件pk","关联活动名称校验失败");
response = globalRewardService.periodCount("18157163293","22565","2");
Assert.assertEquals(response.jsonPath().getString("data"),"1","周期个数校验失败");
}
}
......@@ -26,7 +26,7 @@ import static io.restassured.RestAssured.given;
* Created by 赵然 on 2019/03/29
* AppId: 22565
*/
public class 总帐户账户正常提现 extends DuibaTestBase{
public class 总帐户账户正常提现_AccessTest extends DuibaTestBase{
@Value("${activity.host}")
String activityHost;
@Autowired
......
......@@ -104,6 +104,29 @@ public class GlobalRewardService {
}
return response;
}
/**
* 开发者后台红包周期个数
* @param account
* @param appId
* @param periodStatus 2:进行中
* @return
* @throws Exception
*/
public Response periodCount(String account,String appId,String periodStatus) throws Exception {
logger.info("请求periodCount");
Map<String,String> map = new HashMap<>();
map.put("periodStatus",periodStatus);
Response response = given().contentType("application/x-www-form-urlencoded;charset=UTF-8").cookies(authorization.hdLoginSaasNew(account,appId)).params(map).post("http://"+hdHost+"/redpackets/manageTool/periodCount");
try{
Assert.assertEquals(response.jsonPath().getString("success"),"true","/globalReward/toWithdraw接口失败");
}catch(Exception e){
throw new Exception("/redpackets/manageTool/periodCount接口失败,返回信息:"+response.asString());
}catch(Error er){
throw new Exception("/redpackets/manageTool/periodCount接口失败,返回信息:"+response.asString());
}
return response;
}
}
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