Skip to content

Latest commit

 

History

History
1825 lines (1445 loc) · 69.5 KB

TestRunsApi.md

File metadata and controls

1825 lines (1445 loc) · 69.5 KB

TestRunsApi

All URIs are relative to http://localhost

Method HTTP request Description
apiV2TestRunsDelete DELETE /api/v2/testRuns Delete multiple test runs
apiV2TestRunsIdAutoTestsNamespacesGet GET /api/v2/testRuns/{id}/autoTestsNamespaces Get autotest classes and namespaces in test run
apiV2TestRunsIdDelete DELETE /api/v2/testRuns/{id} Delete test run
apiV2TestRunsIdPurgePost POST /api/v2/testRuns/{id}/purge Permanently delete test run from archive
apiV2TestRunsIdRerunsPost POST /api/v2/testRuns/{id}/reruns Manual autotests rerun in test run
apiV2TestRunsIdRestorePost POST /api/v2/testRuns/{id}/restore Restore test run from the archive
apiV2TestRunsIdStatisticsFilterPost POST /api/v2/testRuns/{id}/statistics/filter Search for the test run test results and build statistics
apiV2TestRunsIdTestPointsResultsGet GET /api/v2/testRuns/{id}/testPoints/results Get test results from the test run grouped by test points
apiV2TestRunsIdTestResultsBulkPut PUT /api/v2/testRuns/{id}/testResults/bulk Partial edit of multiple test results in the test run
apiV2TestRunsIdTestResultsLastModifiedModificationDateGet GET /api/v2/testRuns/{id}/testResults/lastModified/modificationDate Get modification date of last test result of the test run
apiV2TestRunsPurgeBulkPost POST /api/v2/testRuns/purge/bulk Permanently delete multiple test runs from archive
apiV2TestRunsRestoreBulkPost POST /api/v2/testRuns/restore/bulk Restore multiple test runs from the archive
apiV2TestRunsSearchPost POST /api/v2/testRuns/search Search for test runs
apiV2TestRunsUpdateMultiplePost POST /api/v2/testRuns/updateMultiple Update multiple test runs
completeTestRun POST /api/v2/testRuns/{id}/complete Complete TestRun
createAndFillByAutoTests POST /api/v2/testRuns/byAutoTests Create test runs based on autotests and configurations
createAndFillByConfigurations POST /api/v2/testRuns/byConfigurations Create test runs picking the needed test points
createAndFillByWorkItems POST /api/v2/testRuns/byWorkItems Create test run based on configurations and work items
createEmpty POST /api/v2/testRuns Create empty TestRun
getTestRunById GET /api/v2/testRuns/{id} Get TestRun by Id
setAutoTestResultsForTestRun POST /api/v2/testRuns/{id}/testResults Send test results to the test runs in the system
startTestRun POST /api/v2/testRuns/{id}/start Start TestRun
stopTestRun POST /api/v2/testRuns/{id}/stop Stop TestRun
updateEmpty PUT /api/v2/testRuns Update empty TestRun

apiV2TestRunsDelete

Integer apiV2TestRunsDelete(testRunSelectModel)

Delete multiple test runs

Use case User sets selection parameters of test runs System search and delete collection of test runs System returns the number of deleted test runs

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    TestRunSelectModel testRunSelectModel = new TestRunSelectModel(); // TestRunSelectModel | 
    try {
      Integer result = apiInstance.apiV2TestRunsDelete(testRunSelectModel);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsDelete");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
testRunSelectModel TestRunSelectModel [optional]

Return type

Integer

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 - ID is not valid - Project was archived and cannot be edited anymore -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdAutoTestsNamespacesGet

AutoTestNamespacesCountResponse apiV2TestRunsIdAutoTestsNamespacesGet(id)

Get autotest classes and namespaces in test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | 
    try {
      AutoTestNamespacesCountResponse result = apiInstance.apiV2TestRunsIdAutoTestsNamespacesGet(id);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdAutoTestsNamespacesGet");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID

Return type

AutoTestNamespacesCountResponse

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdDelete

apiV2TestRunsIdDelete(id)

Delete test run

Use case User sets test run internal (guid format) identifier System search and delete test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test run internal (UUID) identifier
    try {
      apiInstance.apiV2TestRunsIdDelete(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdDelete");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test run internal (UUID) identifier

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 No Content -
400 - ID is not valid - Project was archived and cannot be edited anymore -
401 Unauthorized -
403 Forbidden -
404 Test run with provided ID cannot be found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdPurgePost

apiV2TestRunsIdPurgePost(id)

Permanently delete test run from archive

Use case User sets archived test run internal (guid format) identifier System search and purge archived test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test run internal (UUID) identifier
    try {
      apiInstance.apiV2TestRunsIdPurgePost(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdPurgePost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test run internal (UUID) identifier

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 No Content -
400 - ID is not valid -
401 Unauthorized -
403 Delete permission for archived test runs is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdRerunsPost

ManualRerunResultModel apiV2TestRunsIdRerunsPost(id, apiV2TestRunsIdRerunsPostRequest)

Manual autotests rerun in test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | 
    ApiV2TestRunsIdRerunsPostRequest apiV2TestRunsIdRerunsPostRequest = new ApiV2TestRunsIdRerunsPostRequest(); // ApiV2TestRunsIdRerunsPostRequest | 
    try {
      ManualRerunResultModel result = apiInstance.apiV2TestRunsIdRerunsPost(id, apiV2TestRunsIdRerunsPostRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdRerunsPost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID
apiV2TestRunsIdRerunsPostRequest ApiV2TestRunsIdRerunsPostRequest [optional]

Return type

ManualRerunResultModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdRestorePost

apiV2TestRunsIdRestorePost(id)

Restore test run from the archive

Use case User sets archived test run internal (guid format) identifier System search and restore test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Unique ID of the test run
    try {
      apiInstance.apiV2TestRunsIdRestorePost(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdRestorePost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Unique ID of the test run

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 No Content -
400 - ID is not valid - Project was archived and cannot be edited anymore -
401 Unauthorized -
403 Read permission for archive is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdStatisticsFilterPost

TestResultsStatisticsGetModel apiV2TestRunsIdStatisticsFilterPost(id, apiV2TestRunsIdStatisticsFilterPostRequest)

Search for the test run test results and build statistics

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test run unique ID
    ApiV2TestRunsIdStatisticsFilterPostRequest apiV2TestRunsIdStatisticsFilterPostRequest = new ApiV2TestRunsIdStatisticsFilterPostRequest(); // ApiV2TestRunsIdStatisticsFilterPostRequest | 
    try {
      TestResultsStatisticsGetModel result = apiInstance.apiV2TestRunsIdStatisticsFilterPost(id, apiV2TestRunsIdStatisticsFilterPostRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdStatisticsFilterPost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test run unique ID
apiV2TestRunsIdStatisticsFilterPostRequest ApiV2TestRunsIdStatisticsFilterPostRequest [optional]

Return type

TestResultsStatisticsGetModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Read permission for test runs is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdTestPointsResultsGet

List<TestPointResultModel> apiV2TestRunsIdTestPointsResultsGet(id)

Get test results from the test run grouped by test points

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test run unique ID
    try {
      List<TestPointResultModel> result = apiInstance.apiV2TestRunsIdTestPointsResultsGet(id);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdTestPointsResultsGet");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test run unique ID

Return type

List<TestPointResultModel>

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Read permission for test runs is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdTestResultsBulkPut

apiV2TestRunsIdTestResultsBulkPut(id, apiV2TestRunsIdTestResultsBulkPutRequest)

Partial edit of multiple test results in the test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test run unique ID
    ApiV2TestRunsIdTestResultsBulkPutRequest apiV2TestRunsIdTestResultsBulkPutRequest = new ApiV2TestRunsIdTestResultsBulkPutRequest(); // ApiV2TestRunsIdTestResultsBulkPutRequest | 
    try {
      apiInstance.apiV2TestRunsIdTestResultsBulkPut(id, apiV2TestRunsIdTestResultsBulkPutRequest);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdTestResultsBulkPut");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test run unique ID
apiV2TestRunsIdTestResultsBulkPutRequest ApiV2TestRunsIdTestResultsBulkPutRequest [optional]

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 No Content -
400 Bad Request -
401 Unauthorized -
403 Update permission for test runs is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsIdTestResultsLastModifiedModificationDateGet

OffsetDateTime apiV2TestRunsIdTestResultsLastModifiedModificationDateGet(id)

Get modification date of last test result of the test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test run unique ID
    try {
      OffsetDateTime result = apiInstance.apiV2TestRunsIdTestResultsLastModifiedModificationDateGet(id);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsIdTestResultsLastModifiedModificationDateGet");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test run unique ID

Return type

OffsetDateTime

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Read permission for test runs is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsPurgeBulkPost

Integer apiV2TestRunsPurgeBulkPost(apiV2TestRunsPurgeBulkPostRequest)

Permanently delete multiple test runs from archive

Use case User sets selection parameters of archived test runs System search and delete collection of archived test runs System returns the number of deleted archived test runs

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    ApiV2TestRunsPurgeBulkPostRequest apiV2TestRunsPurgeBulkPostRequest = new ApiV2TestRunsPurgeBulkPostRequest(); // ApiV2TestRunsPurgeBulkPostRequest | 
    try {
      Integer result = apiInstance.apiV2TestRunsPurgeBulkPost(apiV2TestRunsPurgeBulkPostRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsPurgeBulkPost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
apiV2TestRunsPurgeBulkPostRequest ApiV2TestRunsPurgeBulkPostRequest [optional]

Return type

Integer

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Delete permission for archived test runs is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsRestoreBulkPost

Integer apiV2TestRunsRestoreBulkPost(apiV2TestRunsPurgeBulkPostRequest)

Restore multiple test runs from the archive

Use case User sets selection parameters of archived test runs System search and restore collection of archived test runs System returns the number of restored test runs

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    ApiV2TestRunsPurgeBulkPostRequest apiV2TestRunsPurgeBulkPostRequest = new ApiV2TestRunsPurgeBulkPostRequest(); // ApiV2TestRunsPurgeBulkPostRequest | 
    try {
      Integer result = apiInstance.apiV2TestRunsRestoreBulkPost(apiV2TestRunsPurgeBulkPostRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsRestoreBulkPost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
apiV2TestRunsPurgeBulkPostRequest ApiV2TestRunsPurgeBulkPostRequest [optional]

Return type

Integer

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK -
400 Bad Request -
401 Unauthorized -
403 Read permission for archive is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsSearchPost

List<TestRunShortGetModel> apiV2TestRunsSearchPost(skip, take, orderBy, searchField, searchValue, apiV2TestRunsSearchPostRequest)

Search for test runs

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    Integer skip = 56; // Integer | Amount of items to be skipped (offset)
    Integer take = 56; // Integer | Amount of items to be taken (limit)
    String orderBy = "orderBy_example"; // String | SQL-like  ORDER BY statement (column1 ASC|DESC , column2 ASC|DESC)
    String searchField = "searchField_example"; // String | Property name for searching
    String searchValue = "searchValue_example"; // String | Value for searching
    ApiV2TestRunsSearchPostRequest apiV2TestRunsSearchPostRequest = new ApiV2TestRunsSearchPostRequest(); // ApiV2TestRunsSearchPostRequest | 
    try {
      List<TestRunShortGetModel> result = apiInstance.apiV2TestRunsSearchPost(skip, take, orderBy, searchField, searchValue, apiV2TestRunsSearchPostRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsSearchPost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
skip Integer Amount of items to be skipped (offset) [optional]
take Integer Amount of items to be taken (limit) [optional]
orderBy String SQL-like ORDER BY statement (column1 ASC DESC , column2 ASC
searchField String Property name for searching [optional]
searchValue String Value for searching [optional]
apiV2TestRunsSearchPostRequest ApiV2TestRunsSearchPostRequest [optional]

Return type

List<TestRunShortGetModel>

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 OK * Pagination-Skip - Skipped amount of items
* Pagination-Take - Taken items
* Pagination-Pages - Expected number of pages
* Pagination-Total-Items - Total count of items
400 Bad Request -
401 Unauthorized -
403 Read permission for autotests library is required -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

apiV2TestRunsUpdateMultiplePost

apiV2TestRunsUpdateMultiplePost(apiV2TestRunsUpdateMultiplePostRequest)

Update multiple test runs

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    ApiV2TestRunsUpdateMultiplePostRequest apiV2TestRunsUpdateMultiplePostRequest = new ApiV2TestRunsUpdateMultiplePostRequest(); // ApiV2TestRunsUpdateMultiplePostRequest | 
    try {
      apiInstance.apiV2TestRunsUpdateMultiplePost(apiV2TestRunsUpdateMultiplePostRequest);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#apiV2TestRunsUpdateMultiplePost");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
apiV2TestRunsUpdateMultiplePostRequest ApiV2TestRunsUpdateMultiplePostRequest [optional]

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 No Content -
400 Bad Request -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -
422 Unprocessable Entity -

completeTestRun

completeTestRun(id)

Complete TestRun

Use case User sets test run identifier User runs method execution System completes test run System returns no content response

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.fromString("3fa85f64-5717-4562-b3fc-2c963f66afa6"); // UUID | Test Run internal identifier (GUID format)
    try {
      apiInstance.completeTestRun(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#completeTestRun");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test Run internal identifier (GUID format)

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 Successful operation -
400 Field is required the StateName is already Stopped the StateName is already Completed -
401 Unauthorized -
403 Update permission for test result required -
404 Can't find a TestRun with id! -
409 Conflict -
422 Unprocessable Entity -

createAndFillByAutoTests

TestRunV2GetModel createAndFillByAutoTests(createAndFillByAutoTestsRequest)

Create test runs based on autotests and configurations

This method creates a test run based on an autotest and a configuration. The difference between the `POST /api/v2/testRuns/byWorkItems` and `POST /api/v2/testRuns/byConfigurations` methods is that in this method there is no need to create a test plan and work items (test cases and checklists).

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    CreateAndFillByAutoTestsRequest createAndFillByAutoTestsRequest = new CreateAndFillByAutoTestsRequest(); // CreateAndFillByAutoTestsRequest | 
    try {
      TestRunV2GetModel result = apiInstance.createAndFillByAutoTests(createAndFillByAutoTestsRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#createAndFillByAutoTests");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
createAndFillByAutoTestsRequest CreateAndFillByAutoTestsRequest [optional]

Return type

TestRunV2GetModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
201 Created -
400 - Field is required - Configuration does not exist in the project - Autotest does not exist in the project - Test run must be automated - Project ID is invalid - Autotest external IDs are required - Configuration IDs are required -
401 Unauthorized -
403 Update permission for test results is required -
404 Some autotests do not exist -
409 Conflict -
422 Unprocessable Entity -

createAndFillByConfigurations

TestRunV2GetModel createAndFillByConfigurations(createAndFillByConfigurationsRequest)

Create test runs picking the needed test points

This method creates a test run based on a combination of a configuration and a work item(test case or checklist). Before you create a test run using this method, make sure to create a test plan. Work items must be automated. This method is different from the `POST /api/v2/testRuns/byWorkItems` method because of the ability to send a jagged array within the &quot;<b>testPointSelectors</b>&quot; parameter.

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    CreateAndFillByConfigurationsRequest createAndFillByConfigurationsRequest = new CreateAndFillByConfigurationsRequest(); // CreateAndFillByConfigurationsRequest | 
    try {
      TestRunV2GetModel result = apiInstance.createAndFillByConfigurations(createAndFillByConfigurationsRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#createAndFillByConfigurations");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
createAndFillByConfigurationsRequest CreateAndFillByConfigurationsRequest [optional]

Return type

TestRunV2GetModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
201 Created -
400 - Field is required - Test run cannot be created with deleted test points - Test suites with IDs [ids] is archived - Configurations with IDs [ids] is archived - Test run cannot be created with non-automated test point - Test run must be automated - Some work items do not exist - Project ID is invalid - Test point selectors are required - Some work item IDs are invalid - Some configuration IDs are invalid -
401 Unauthorized -
403 Update permission for test results is required -
404 Some test points do not exists -
409 Conflict -
422 Unprocessable Entity -

createAndFillByWorkItems

TestRunV2GetModel createAndFillByWorkItems(createAndFillByWorkItemsRequest)

Create test run based on configurations and work items

This method creates a test run based on a combination of configuration and work item (test case or checklist). Before you create a test run using this method, make sure to create a test plan. Work items must be automated.

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    CreateAndFillByWorkItemsRequest createAndFillByWorkItemsRequest = new CreateAndFillByWorkItemsRequest(); // CreateAndFillByWorkItemsRequest | 
    try {
      TestRunV2GetModel result = apiInstance.createAndFillByWorkItems(createAndFillByWorkItemsRequest);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#createAndFillByWorkItems");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
createAndFillByWorkItemsRequest CreateAndFillByWorkItemsRequest [optional]

Return type

TestRunV2GetModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
201 Created -
400 - Field is required - Test run cannot be created with deleted test points - Test suites with IDs [ids] is archived - Configurations with IDs [ids] is archived - Test run cannot be created with non-automated test point - Some work items do not exist - Project ID is invalid -
401 Unauthorized -
403 Update permission for test results is required -
404 Some test points, work items or configurations do not exist -
409 Conflict -
422 Unprocessable Entity -

createEmpty

TestRunV2GetModel createEmpty(testRunV2PostShortModel)

Create empty TestRun

Use case User sets test run model (listed in the request example) User runs method execution System creates test run System returns test run model

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    TestRunV2PostShortModel testRunV2PostShortModel = new TestRunV2PostShortModel(); // TestRunV2PostShortModel | 
    try {
      TestRunV2GetModel result = apiInstance.createEmpty(testRunV2PostShortModel);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#createEmpty");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
testRunV2PostShortModel TestRunV2PostShortModel [optional]

Return type

TestRunV2GetModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
201 Successful operation -
400 Field is required TestRun must be automated ProjectId is not a valid! -
401 TestRunTesterRequirement permission required -
403 Update permission for test result required -
404 Can't find a TestRun with id = testRunId -
409 Conflict -
422 Unprocessable Entity -

getTestRunById

TestRunV2GetModel getTestRunById(id)

Get TestRun by Id

Use case User sets test run identifier User runs method execution System finds test run System returns test run

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.fromString("3fa85f64-5717-4562-b3fc-2c963f66afa6"); // UUID | Test Run internal identifier (GUID format)
    try {
      TestRunV2GetModel result = apiInstance.getTestRunById(id);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#getTestRunById");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test Run internal identifier (GUID format)

Return type

TestRunV2GetModel

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Successful operation -
400 Bad Request -
401 Unauthorized -
403 Read permission for test result required -
404 TestRun with ID '{id}' does not exist. -
409 Conflict -
422 Unprocessable Entity -

setAutoTestResultsForTestRun

List<UUID> setAutoTestResultsForTestRun(id, autoTestResultsForTestRunModel)

Send test results to the test runs in the system

This method sends test results to the test management system.

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.randomUUID(); // UUID | Test Run internal identifier (GUID format)
    List<AutoTestResultsForTestRunModel> autoTestResultsForTestRunModel = Arrays.asList(); // List<AutoTestResultsForTestRunModel> | 
    try {
      List<UUID> result = apiInstance.setAutoTestResultsForTestRun(id, autoTestResultsForTestRunModel);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#setAutoTestResultsForTestRun");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test Run internal identifier (GUID format)
autoTestResultsForTestRunModel List<AutoTestResultsForTestRunModel> [optional]

Return type

List<UUID>

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Successful operation -
400 - Field is required - Body is invalid - Test points are required - Duration must be a positive number - Outcome is not defined - Test run is stopped -
401 Unauthorized -
403 Update permission for test results is required -
404 - Test run with provided ID was not found - Test point was not found - Autotest with provided external ID was not found -
409 Conflict -
422 - Configuration with provided ID was not found - Test points relevant to provided filters were not found -

startTestRun

startTestRun(id)

Start TestRun

Use case User sets test run identifier User runs method execution System starts test run System returns no content response

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.fromString("3fa85f64-5717-4562-b3fc-2c963f66afa6"); // UUID | Test Run internal identifier (GUID format)
    try {
      apiInstance.startTestRun(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#startTestRun");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test Run internal identifier (GUID format)

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 Successful operation -
400 Field is required the StateName is already InProgress the StateName is already Stopped the StateName is already Completed -
401 Unauthorized -
403 Update permission for test result required -
404 Can't find a TestRun with id! -
409 Conflict -
422 Unprocessable Entity -

stopTestRun

stopTestRun(id)

Stop TestRun

Use case User sets test run identifier User runs method execution System stops test run System returns no content response

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    UUID id = UUID.fromString("3fa85f64-5717-4562-b3fc-2c963f66afa6"); // UUID | Test Run internal identifier (GUID format)
    try {
      apiInstance.stopTestRun(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#stopTestRun");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
id UUID Test Run internal identifier (GUID format)

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 Successful operation -
400 Field is required the StateName is already Stopped the StateName is already Completed -
401 Unauthorized -
403 Update permission for test result required -
404 Can't find a TestRun with id! -
409 Conflict -
422 Unprocessable Entity -

updateEmpty

updateEmpty(testRunV2PutModel)

Update empty TestRun

Use case User sets test run properties (listed in the request example) User runs method execution System updates test run System returns returns no content response

Example

// Import classes:
import ru.testit.client.invoker.ApiClient;
import ru.testit.client.invoker.ApiException;
import ru.testit.client.invoker.Configuration;
import ru.testit.client.invoker.auth.*;
import ru.testit.client.invoker.models.*;
import ru.testit.client.api.TestRunsApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");
    
    // Configure API key authorization: Bearer or PrivateToken
    ApiKeyAuth Bearer or PrivateToken = (ApiKeyAuth) defaultClient.getAuthentication("Bearer or PrivateToken");
    Bearer or PrivateToken.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //Bearer or PrivateToken.setApiKeyPrefix("Token");

    TestRunsApi apiInstance = new TestRunsApi(defaultClient);
    TestRunV2PutModel testRunV2PutModel = new TestRunV2PutModel(); // TestRunV2PutModel | 
    try {
      apiInstance.updateEmpty(testRunV2PutModel);
    } catch (ApiException e) {
      System.err.println("Exception when calling TestRunsApi#updateEmpty");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

Name Type Description Notes
testRunV2PutModel TestRunV2PutModel [optional]

Return type

null (empty response body)

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

HTTP response details

Status code Description Response headers
204 Successful operation -
400 Field is required Name is not valid -
401 Unauthorized -
403 Update permission for test result required -
404 Can't find a TestRun with id! -
409 Conflict -
422 Unprocessable Entity -