Commit d033921d by yangjian

编辑会员卡时,identifier不能随机生成

parent 469b4b0c
......@@ -39,10 +39,19 @@ public class TestTenantMemberCard_update extends XMBaseTest {
e.printStackTrace();
}
Cardtools.memberCardCreate("次卡-自动化会员卡"+ RandomStringUtil.randomString(3));//创建随机的名的次卡
Cardtools.fetchPageOfMemberCard("MEMBER_CARD");
Cardtools.fetchPageOfMemberCard("MEMBER_CARD");
String memberCardId = XMJSONPath.readPath(dataApi.getApi_response(), "$.result.records[0].id");
Cardtools.fetchDetailById(memberCardId);
String id = XMJSONPath.readPath(dataApi.getApi_response(), "$.result.benefitList[0].id");
String identifier = XMJSONPath.readPath(dataApi.getApi_response(), "$.result.benefitList[0].identifier");
JSONObject bodyJson2 =Cardtools.fetchPageOfHistory(memberCardId);
int count = Integer.parseInt(XMJSONPath.readPath(bodyJson2,"$.result.total"));
......@@ -56,7 +65,8 @@ public class TestTenantMemberCard_update extends XMBaseTest {
//List itemList = new ArrayList();
//itemList.add("");
JSONObject Object = new JSONObject();
Object.put("identifier", RandomStringUtil.randomString(20));
Object.put("id", id);
Object.put("identifier", identifier);
Object.put("benefitType", "BALANCE");
Object.put("targetScope", "GROUP_CLASS_AND_PERSONAL_COURSE");
Object.put("balance", "30");
......
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