Commit 9d6b2408 authored by 龚小红's avatar 龚小红

Merge branch 'Feature/20211126-gxh' into 'master'

1.修复支付接口Pay未上架导致的用户非会员问题(暂时性)。

See merge request test-group/kejiji!173
parents 23b29276 a97ebc81
...@@ -34,7 +34,7 @@ public class Pay implements Authorization { ...@@ -34,7 +34,7 @@ public class Pay implements Authorization {
@Test (description = "默认付费_续费页",priority = 1) //priority 方法执行优先级 @Test (description = "默认付费_续费页",priority = 1) //priority 方法执行优先级
public void 默认付费_续费页() { public void 默认付费_续费页() {
//切换会员为会员状态 //切换会员为会员状态
updateTypeOrDate(5495,true); updateTypeOrDate(5495,true);
//代理人续费状态 //代理人续费状态
Map<String, Object> payParams = new HashMap<String, Object>(); Map<String, Object> payParams = new HashMap<String, Object>();
...@@ -80,7 +80,7 @@ public class Pay implements Authorization { ...@@ -80,7 +80,7 @@ public class Pay implements Authorization {
Assert.assertEquals(preferentialPrice,4,network.message(PAY_info,"正常价格非0.04",response.body().asString())); Assert.assertEquals(preferentialPrice,4,network.message(PAY_info,"正常价格非0.04",response.body().asString()));
} }
@Test (description = "默认付费_待支付",priority = 5) @Test (description = "默认付费_待支付",priority = 4)
public void 默认付费_待支付() { public void 默认付费_待支付() {
//创建支付 //创建支付
Map<String, Object> payParams = new HashMap<String, Object>(); Map<String, Object> payParams = new HashMap<String, Object>();
...@@ -93,7 +93,7 @@ public class Pay implements Authorization { ...@@ -93,7 +93,7 @@ public class Pay implements Authorization {
} }
@Test (description = "默认付费_查询订单状态",priority = 6) @Test (description = "默认付费_查询订单状态",priority = 5)
public void 默认付费_查询订单状态() { public void 默认付费_查询订单状态() {
Map<String, Object> cancelParams = new HashMap<String, Object>(); Map<String, Object> cancelParams = new HashMap<String, Object>();
cancelParams.put("tradeNo",tradeNo); cancelParams.put("tradeNo",tradeNo);
...@@ -102,7 +102,7 @@ public class Pay implements Authorization { ...@@ -102,7 +102,7 @@ public class Pay implements Authorization {
Assert.assertEquals(data,2,network.message(cancelParams, PAY_result,"订单状态不为待付款",response.body().asString())); Assert.assertEquals(data,2,network.message(cancelParams, PAY_result,"订单状态不为待付款",response.body().asString()));
} }
@Test (description = "好友代付_弹窗信息",priority = 7) @Test (description = "好友代付_弹窗信息",priority = 6)
public void 好友代付_弹窗信息() { public void 好友代付_弹窗信息() {
Map<String, Object> params = new HashMap<String, Object>(); Map<String, Object> params = new HashMap<String, Object>();
params.put("entryDiscountType",1); params.put("entryDiscountType",1);
...@@ -113,7 +113,7 @@ public class Pay implements Authorization { ...@@ -113,7 +113,7 @@ public class Pay implements Authorization {
Assert.assertNotNull(data,network.message(params, PAY_popup,"好友代付-付款码为空",response.body().asString())); Assert.assertNotNull(data,network.message(params, PAY_popup,"好友代付-付款码为空",response.body().asString()));
} }
@Test (description = "默认付费_取消支付",priority = 8) @Test (description = "默认付费_取消支付",priority = 7)
public void 默认付费_取消支付() { public void 默认付费_取消支付() {
Map<String, Object> cancelParams = new HashMap<String, Object>(); Map<String, Object> cancelParams = new HashMap<String, Object>();
cancelParams.put("tradeNo",tradeNo); cancelParams.put("tradeNo",tradeNo);
...@@ -122,7 +122,7 @@ public class Pay implements Authorization { ...@@ -122,7 +122,7 @@ public class Pay implements Authorization {
Assert.assertEquals(result,"OK",network.message(cancelParams, PAY_cancel,"取消支付:取消支付失败",response.body().asString())); //判断返回的微信调起参数中appId是否正确 Assert.assertEquals(result,"OK",network.message(cancelParams, PAY_cancel,"取消支付:取消支付失败",response.body().asString())); //判断返回的微信调起参数中appId是否正确
} }
@Test (description = "默认付费_取消后查询订单状态",priority = 9) @Test (description = "默认付费_取消后查询订单状态",priority = 8)
public void 默认付费_取消后查询订单状态() { public void 默认付费_取消后查询订单状态() {
Map<String, Object> cancelParams = new HashMap<String, Object>(); Map<String, Object> cancelParams = new HashMap<String, Object>();
cancelParams.put("tradeNo",tradeNo); cancelParams.put("tradeNo",tradeNo);
...@@ -131,7 +131,7 @@ public class Pay implements Authorization { ...@@ -131,7 +131,7 @@ public class Pay implements Authorization {
Assert.assertEquals(data,5,network.message(cancelParams, PAY_result,"取消支付:取消支付失败",response.body().asString())); //判断返回的微信调起参数中appId是否正确 Assert.assertEquals(data,5,network.message(cancelParams, PAY_result,"取消支付:取消支付失败",response.body().asString())); //判断返回的微信调起参数中appId是否正确
} }
@Test (description = "默认付费_切换会员类型为保险版",priority = 10) @Test (description = "默认付费_切换会员类型为保险版",priority = 9)
public void 默认付费_切换为保险版会员类型(){ public void 默认付费_切换为保险版会员类型(){
//会员类型版本判断 //会员类型版本判断
Map<String, Object> params = new HashMap<String, Object>(); Map<String, Object> params = new HashMap<String, Object>();
...@@ -159,6 +159,9 @@ public class Pay implements Authorization { ...@@ -159,6 +159,9 @@ public class Pay implements Authorization {
result = response.jsonPath().getString("desc"); result = response.jsonPath().getString("desc");
Assert.assertEquals(result,"OK",network.message(versionParams,PAY_exchange,"会员类型切换:切换失败",response.body().asString())); //判断返回的微信调起参数中appId是否正确 Assert.assertEquals(result,"OK",network.message(versionParams,PAY_exchange,"会员类型切换:切换失败",response.body().asString())); //判断返回的微信调起参数中appId是否正确
} }
//切换会员为会员状态
updateTypeOrDate(5495,true);
} }
// //
// @Test (description = "创建优惠码",priority = 11) // @Test (description = "创建优惠码",priority = 11)
......
...@@ -481,6 +481,7 @@ public class WhoSawMe implements Authorization { ...@@ -481,6 +481,7 @@ public class WhoSawMe implements Authorization {
// 团队架构_删除团队成员 // 团队架构_删除团队成员
@Test(description = "团队架构_删除团队成员", priority = 100) @Test(description = "团队架构_删除团队成员", priority = 100)
public void 团队架构_删除团队成员() throws IOException{ public void 团队架构_删除团队成员() throws IOException{
visitor2Tku();
List<String> sids = new ArrayList<>(); List<String> sids = new ArrayList<>();
sids.add(ForwardAndRead.encodeId(childSellerId)); sids.add(ForwardAndRead.encodeId(childSellerId));
param = new HashMap<>(); param = new HashMap<>();
...@@ -955,6 +956,5 @@ public class WhoSawMe implements Authorization { ...@@ -955,6 +956,5 @@ public class WhoSawMe implements Authorization {
response = network.postResponse(param,GAME_consult); response = network.postResponse(param,GAME_consult);
String sCid = response.jsonPath().getString("data"); String sCid = response.jsonPath().getString("data");
Assert.assertNotNull(reportScid, network.message(param,GAME_consult,"获取sCid失败",response.body().asString())); Assert.assertNotNull(reportScid, network.message(param,GAME_consult,"获取sCid失败",response.body().asString()));
} }
} }
...@@ -130,7 +130,6 @@ public class BaseUtils { ...@@ -130,7 +130,6 @@ public class BaseUtils {
Assert.assertTrue(success,network.message(params,MANAGER_changeCompany,"接口返回失败",response.body().asString())); Assert.assertTrue(success,network.message(params,MANAGER_changeCompany,"接口返回失败",response.body().asString()));
Assert.assertTrue(result,network.message(params,MANAGER_changeCompany,"返回数据为空",response.body().asString())); Assert.assertTrue(result,network.message(params,MANAGER_changeCompany,"返回数据为空",response.body().asString()));
SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");//设置日期格式
Date date = new Date();// new Date()为获取当前系统时间 Date date = new Date();// new Date()为获取当前系统时间
Calendar cal = Calendar.getInstance(); Calendar cal = Calendar.getInstance();
cal.setTime(date); cal.setTime(date);
...@@ -138,8 +137,8 @@ public class BaseUtils { ...@@ -138,8 +137,8 @@ public class BaseUtils {
params.put("reason", "测试账号"); params.put("reason", "测试账号");
params.put("sellerId", sellerId); params.put("sellerId", sellerId);
params.put("userVersion", 2); params.put("userVersion", 2);
params.put("vipStartDate", df.format(date)); params.put("vipStartDate", System.currentTimeMillis());
params.put("vipEndDate", df.format(cal.getTime())); params.put("vipEndDate", cal.getTime());
if(choice) { if(choice) {
//切换会员 //切换会员
params.put("vipType", 2); params.put("vipType", 2);
......
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