Commit b4744afd authored by 马博's avatar 马博

changes

parent 8875e60e
......@@ -261,6 +261,12 @@
<artifactId>guava</artifactId>
<version>21.0</version>
</dependency>
<dependency>
<groupId>cn.com.duiba.tool</groupId>
<artifactId>java-gitlab-api</artifactId>
<version>1.3.8</version>
</dependency>
</dependencies>
<build>
......
......@@ -52,6 +52,10 @@ public class DingdingResult {
names.addAll(Arrays.asList(getNames));
Map<String,String> params = new HashMap<>();
params.put("jobName",getJob());
changes = Postman.sendFindTestApp(params);
/*从jenkins上获取项目变更
Map<String,String> resentChanges=BeTested.getChangesWithin(30,changeMap);
System.out.println(resentChanges);
if(resentChanges!=null&&resentChanges.size()>0){
......@@ -77,7 +81,7 @@ public class DingdingResult {
if(changes.length()>140){
changes=changes.substring(0,141)+"……";
}
//project="tuia-media";
*/
this.total=total;
this.passCount=passCount;
this.skipCount=skipCount;
......
......@@ -25,6 +25,7 @@ public class Postman {
final static String testPlatformUrl = "http://101.37.27.82:8080/insert";
final static String miriaUrl = "http://miria-aliyun.duibatest.com.cn/autoTest/finish";
final static String miriaUrlTesting = "http://miria-aliyun.duibatest.com.cn/autoTest/testing";
final static String miriaUrlFindTestApp = "http://miria-aliyun.duibatest.com.cn/autoTest/findTestApp";
//dingdingUrl="http://www.json.cn/";
private static Logger logger = LogManager.getLogger(Postman.class);
......@@ -67,6 +68,15 @@ public class Postman {
System.out.println("miriaUrl:"+miriaUrlTesting);
System.out.println("miria响应结果:"+response.asString());
}
public static String sendFindTestApp(Map result){
Response response=given().params(result).get(miriaUrlFindTestApp);
System.out.println("jobName:"+result.get("jobName"));
System.out.println("miriaUrl:"+miriaUrlTesting);
System.out.println("miria响应结果:"+response.asString());
String value = response.jsonPath().getString("value");
return value;
}
public static Boolean getName(){
Calendar c = Calendar.getInstance();
Date date = new Date();
......
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