Commit 5c6fca8c authored by 周松波's avatar 周松波

add 2 cases

parent 72ab0dc1
......@@ -318,32 +318,28 @@ public class ContractSign_signTest extends DuibaTestBase {
}
private void modifyJoinTime(String actId, String date, String startTime, String endTime) throws Exception{
String jsonBody = String.format("{" +
"\"title\":\"自动化_报名截止时间\"," +
"\"betCount\":1000," +
"\"betType\":2," +
"\"openType\":0," +
"\"rangeList\":[]," +
"\"enableAmpifyCard\":false," +
"\"bonusType\":0," +
"\"bankerBonus\":10000," +
"\"ruleDesc\":null," +
"\"contractCycle\":7," +
"\"joinTimeLimit\":false," +
"\"fakeLimit\":false," +
"\"rankPeriod\":1," +
"\"mockValue\":0," +
"\"joinTimeStart\": \"%s\"," +
"\"joinTimeEnd\": \"%s\"," +
"\"joinDeadLine\": \"%s\"," +
"\"actId\":%s," +
"\"openStatus\":true," +
"\"gradientAmountList\":\"\"," +
"\"freeJoinLimit\":0," +
"\"fakeRatio\":0" +
"}", startTime, endTime, date, actId);
System.out.println(jsonBody);
Response response = given().contentType("application/json;charset=UTF-8").cookies(authorization.ssoLogin()).body(jsonBody).post("https://mng.duibatest.com.cn/newmanager/signContract/save");
Map<String, Object> map = new HashMap<>();
map.put("title", "自动化_报名截止时间");
map.put("betCount", "1000");
map.put("bonusType","0");
map.put("betType","2");
map.put("bankerBonus", "10000");
map.put("ruleDesc:", "<p>bao ming&nbsp;截止时间</p>");
map.put("contractCycle","7");
map.put("joinTimeLimit", false);
map.put("fakeLimit", false);
map.put("rankPeriod","1");
map.put("joinTimeStart", startTime);
map.put("joinTimeEnd", endTime);
map.put("joinDeadLine", date);
map.put("actId", actId);
map.put("openStatus", true);
map.put("gradientAmountList","");
map.put("freeJoinLimit", "0");
map.put("enableAmpifyCard",false);
map.put("openType", "0");
JSONObject jsonObject = JSONObject.parseObject(JSON.toJSONString(map));
Response response = given().contentType("application/json;charset=UTF-8").cookies(authorization.ssoLogin()).body(jsonObject).post("https://mng.duibatest.com.cn/newmanager/signContract/save");
response.prettyPrint();
try {
Assert.assertEquals(response.jsonPath().getString("success"), "true", "/signContract/save接口失败");
......
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