diff --git a/pom.xml b/pom.xml index 57759704..82508b01 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.testdroid testdroid-api - 2.42 + 2.43-SNAPSHOT jar Testdroid API v2 https://github.com/bitbar/testdroid-api diff --git a/src/main/java/com/testdroid/api/model/APIProject.java b/src/main/java/com/testdroid/api/model/APIProject.java index b6bb4c83..b6a95da0 100644 --- a/src/main/java/com/testdroid/api/model/APIProject.java +++ b/src/main/java/com/testdroid/api/model/APIProject.java @@ -319,6 +319,15 @@ private Map getCreateRunParameters(String testRunName, List getCreateRunParameters(String testRunName, String deviceNamePattern, + Long testRunId) { + Map result = new HashMap<>(); + result.putAll(getCreateRunParameters(testRunName)); + result.put("deviceNamePattern", deviceNamePattern); + result.putAll(getCreateRunParameters(testRunId)); + return result; + } + private Map getCreateParameterParameters(final String key, final String value) { Map map = new HashMap<>(); map.put("key", key); @@ -389,6 +398,12 @@ public APITestRun run(String testRunName, List usedDevicesId, Long testRun return postResource(getRunsURI(), getCreateRunParameters(testRunName, usedDevicesId, testRunId), APITestRun.class); } + @JsonIgnore + public APITestRun run(String testRunName, String deviceNamePattern, Long testRunId) throws APIException { + return postResource(getRunsURI(), getCreateRunParameters(testRunName, deviceNamePattern, testRunId), + APITestRun.class); + } + @JsonIgnore public APITestRun runWithConfig( String testRunName, List deviceIds, APITestRunConfig config, Long appFileId, Long testFileId,