Commit 2c595630 authored by 马博's avatar 马博

Merge branch 'master' of gitlab2.dui88.com:mabo/test-platform

parents 88a78ed3 4b24a25b
......@@ -12,4 +12,5 @@ public class Database {
public static String orders5 = "orders_0209";
public static String orders6 = "orders_0210";
public static String orders7 = "orders_0211";
public static String orders8 = "orders_0090";
}
......@@ -150,6 +150,7 @@ public class ObjectExchange_ExchangeTest extends DuibaTestBase{
//直充类单档话费兑换_1元话费
@Test(description = "直充类单档话费兑换")
public void phonebillDingzhi() throws Exception {
Thread.sleep(2000);
Map<String, Object> mapuser = jdbc.findSimpleResult("select * from dafuweng.user where id="+uid);
String credits = String.valueOf(mapuser.get("credits"));
logger.info("兑换前积分:" + credits);
......@@ -194,6 +195,7 @@ public class ObjectExchange_ExchangeTest extends DuibaTestBase{
}
//查询数据库,获取当前积分
Thread.sleep(2000);
mapuser = jdbc.findSimpleResult("select * from dafuweng.user where id="+uid);
String creditsNew = String.valueOf(mapuser.get("credits"));
logger.info("兑换后积分:" + creditsNew);
......
package http.cases.GameTest;
import base.Config;
import base.DuibaLog;
import http.service.Activity.ManagerService;
import http.service.Activity.NgapiService;
......@@ -33,6 +34,7 @@ import static org.hamcrest.Matchers.equalTo;
* case3:游戏测试:马上使用跳转优惠券兑换记录页的链接
* case4:游戏测试:马上使用跳转福袋的链接
*/
@ContextConfiguration(classes = Config.class)
public class Game_AccessTest extends AbstractTestNGSpringContextTests {
@Autowired
......
......@@ -34,9 +34,10 @@ public class 游戏_中奖优惠券_AccessTest extends DuibaTestBase {
private static DuibaLog logger = DuibaLog.getLogger();
private String virtualOrderIds = null;
private static final Integer uid_Nomal = 2708;
private static final String consumerId = "100011623";
// private static final Integer uid_Nomal = 2708;
// private static final String consumerId = "100011623";
private static final Integer uid_Nomal = 4390;
private static final String consumerId = "100094047";
......
......@@ -33,7 +33,8 @@ public class 游戏_中奖异常流程测试_AccessTest extends DuibaTestBase {
NewGameService newGameService;
private static DuibaLog logger = DuibaLog.getLogger();
private static final Integer uid_Nomal = 2708;
//private static final Integer uid_Nomal = 2708;
private static final Integer uid_Nomal = 4389;
//ok
......
......@@ -36,8 +36,10 @@ public class 游戏_中奖限制测试_AccessTest extends DuibaTestBase {
NewGameService newGameService;
private static final Integer uid_Nomal = 2708;
private static final String consumerId_Nomal = "100011623";
// private static final Integer uid_Nomal = 2708;
// private static final String consumerId_Nomal = "100011623";
private static final Integer uid_Nomal = 4388;
private static final String consumerId_Nomal = "100094045";
private static DuibaLog logger = DuibaLog.getLogger();
......
......@@ -35,9 +35,10 @@ public class 游戏_奖项限制测试_AccessTest extends DuibaTestBase {
NewGameService newGameService;
private static DuibaLog logger = DuibaLog.getLogger();
private static final Integer uid_Nomal = 2708;
private static final String consumerId = "100011623";
// private static final Integer uid_Nomal = 2708;
// private static final String consumerId = "100011623";
private static final Integer uid_Nomal = 4387;
private static final String consumerId = "100094044";
......
......@@ -76,7 +76,7 @@ public class DeveloperAccountService {
map.put("mode","two");
map.put("orderId",orderId);
map.put("rowId","1");
Response response=given().cookies(authorization.hdLogin()).params(map).get("http://"+url);
Response response=given().cookies(authorization.hdLoginCommon("zhaoran@duiba.com.cn")).params(map).get("http://"+url);
try{
Assert.assertEquals(response.jsonPath().getString("success"),"true","/developerAccount/cashDetail接口失败");
......
......@@ -49,9 +49,28 @@ public class DsOrderService {
throw new Exception("请求订单审核接口失败,返回信息:"+response.asString());
}
return response;
}
//审核订单
public Response submitAudit(String idArray,String audit,String email) throws Exception{
String url = hdHost + "/dsOrder/submitAudit";
}
Map<String,String> map = new HashMap<>();
map.put("appId","18714");
map.put("idArray",idArray);
map.put("audit",audit);
map.put("reason","测试订单审核不通过");
logger.info("请求订单审核接口:" + url);
Response response=given().contentType("application/x-www-form-urlencoded;charset=UTF-8").cookies(authorization.hdLoginCommon(email)).params(map).post("http://"+url);
try{
Assert.assertEquals(response.jsonPath().getString("desc"),"成功");
}catch(Exception e){
throw new Exception("请求订单审核接口失败,返回信息:"+response.asString());
}catch(Error er){
throw new Exception("请求订单审核接口失败,返回信息:"+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