Skip to content

Commit

Permalink
Updates to Results API
Browse files Browse the repository at this point in the history
  • Loading branch information
n3r committed Aug 10, 2023
1 parent 08f50a0 commit cc90d67
Show file tree
Hide file tree
Showing 49 changed files with 3,751 additions and 34 deletions.
13 changes: 12 additions & 1 deletion qaseio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ Class | Method | HTTP request | Description
*AttachmentsApi* | [**upload_attachment**](docs/AttachmentsApi.md#upload_attachment) | **POST** /attachment/{code} | Upload attachment.
*AuthorsApi* | [**get_author**](docs/AuthorsApi.md#get_author) | **GET** /author/{id} | Get a specific author.
*AuthorsApi* | [**get_authors**](docs/AuthorsApi.md#get_authors) | **GET** /author | Get all authors.
*CasesApi* | [**bulk**](docs/CasesApi.md#bulk) | **POST** /case/{code}/bulk | Create a new test cases.
*CasesApi* | [**bulk**](docs/CasesApi.md#bulk) | **POST** /case/{code}/bulk | Create test cases in bulk.
*CasesApi* | [**create_case**](docs/CasesApi.md#create_case) | **POST** /case/{code} | Create a new test case.
*CasesApi* | [**delete_case**](docs/CasesApi.md#delete_case) | **DELETE** /case/{code}/{id} | Delete test case.
*CasesApi* | [**get_case**](docs/CasesApi.md#get_case) | **GET** /case/{code}/{id} | Get a specific test case.
Expand Down Expand Up @@ -138,6 +138,7 @@ Class | Method | HTTP request | Description
*ProjectsApi* | [**get_projects**](docs/ProjectsApi.md#get_projects) | **GET** /project | Get All Projects.
*ProjectsApi* | [**grant_access_to_project**](docs/ProjectsApi.md#grant_access_to_project) | **POST** /project/{code}/access | Grant access to project by code.
*ProjectsApi* | [**revoke_access_to_project**](docs/ProjectsApi.md#revoke_access_to_project) | **DELETE** /project/{code}/access | Revoke access to project by code.
*ResultApi* | [**create_results_v2**](docs/ResultApi.md#create_results_v2) | **POST** /{project_code}/run/{run_id}/results |
*ResultsApi* | [**create_result**](docs/ResultsApi.md#create_result) | **POST** /result/{code}/{id} | Create test run result.
*ResultsApi* | [**create_result_bulk**](docs/ResultsApi.md#create_result_bulk) | **POST** /result/{code}/{id}/bulk | Bulk create test run result.
*ResultsApi* | [**delete_result**](docs/ResultsApi.md#delete_result) | **DELETE** /result/{code}/{id}/{hash} | Delete test run result.
Expand Down Expand Up @@ -191,6 +192,8 @@ Class | Method | HTTP request | Description
- [CreateResult200Response](docs/CreateResult200Response.md)
- [CreateResult200ResponseAllOf](docs/CreateResult200ResponseAllOf.md)
- [CreateResult200ResponseAllOfResult](docs/CreateResult200ResponseAllOfResult.md)
- [CreateResultsRequestV2](docs/CreateResultsRequestV2.md)
- [CreateResultsRequestV2ResultsInner](docs/CreateResultsRequestV2ResultsInner.md)
- [CustomField](docs/CustomField.md)
- [CustomFieldCreate](docs/CustomFieldCreate.md)
- [CustomFieldCreateValueInner](docs/CustomFieldCreateValueInner.md)
Expand Down Expand Up @@ -260,17 +263,25 @@ Class | Method | HTTP request | Description
- [QqlDefect](docs/QqlDefect.md)
- [QqlPlan](docs/QqlPlan.md)
- [QqlTestCase](docs/QqlTestCase.md)
- [RelationSuite](docs/RelationSuite.md)
- [RelationSuiteItem](docs/RelationSuiteItem.md)
- [Requirement](docs/Requirement.md)
- [Response](docs/Response.md)
- [Result](docs/Result.md)
- [ResultAttachment](docs/ResultAttachment.md)
- [ResultCreate](docs/ResultCreate.md)
- [ResultCreateBulk](docs/ResultCreateBulk.md)
- [ResultCreateCase](docs/ResultCreateCase.md)
- [ResultExecution](docs/ResultExecution.md)
- [ResultListResponse](docs/ResultListResponse.md)
- [ResultListResponseAllOf](docs/ResultListResponseAllOf.md)
- [ResultListResponseAllOfResult](docs/ResultListResponseAllOfResult.md)
- [ResultRelations](docs/ResultRelations.md)
- [ResultResponse](docs/ResultResponse.md)
- [ResultResponseAllOf](docs/ResultResponseAllOf.md)
- [ResultStep](docs/ResultStep.md)
- [ResultStepData](docs/ResultStepData.md)
- [ResultStepExecution](docs/ResultStepExecution.md)
- [ResultUpdate](docs/ResultUpdate.md)
- [Run](docs/Run.md)
- [RunCreate](docs/RunCreate.md)
Expand Down
4 changes: 2 additions & 2 deletions qaseio/docs/BulkRequestCasesInner.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ Name | Type | Description | Notes
**tags** | **[str]** | | [optional]
**params** | **{str: ([str],)}, none_type** | | [optional]
**custom_field** | **{str: (str,)}** | A map of custom fields values (id => value) | [optional]
**created_at** | **datetime** | | [optional]
**updated_at** | **datetime** | | [optional]
**created_at** | **str** | | [optional]
**updated_at** | **str** | | [optional]
**id** | **int, none_type** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

Expand Down
10 changes: 5 additions & 5 deletions qaseio/docs/CasesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ All URIs are relative to *https://api.qase.io/v1*

Method | HTTP request | Description
------------- | ------------- | -------------
[**bulk**](CasesApi.md#bulk) | **POST** /case/{code}/bulk | Create a new test cases.
[**bulk**](CasesApi.md#bulk) | **POST** /case/{code}/bulk | Create test cases in bulk.
[**create_case**](CasesApi.md#create_case) | **POST** /case/{code} | Create a new test case.
[**delete_case**](CasesApi.md#delete_case) | **DELETE** /case/{code}/{id} | Delete test case.
[**get_case**](CasesApi.md#get_case) | **GET** /case/{code}/{id} | Get a specific test case.
Expand All @@ -15,7 +15,7 @@ Method | HTTP request | Description
# **bulk**
> Bulk200Response bulk(code, bulk_request)
Create a new test cases.
Create test cases in bulk.

This method allows to bulk create new test cases in a project.

Expand Down Expand Up @@ -60,7 +60,7 @@ with qaseio.ApiClient(configuration) as api_client:

# example passing only required values which don't have defaults set
try:
# Create a new test cases.
# Create test cases in bulk.
api_response = api_instance.bulk(code, bulk_request)
pprint(api_response)
except qaseio.ApiException as e:
Expand Down Expand Up @@ -186,8 +186,8 @@ with qaseio.ApiClient(configuration) as api_client:
custom_field={
"key": "key_example",
},
created_at=dateutil_parser('1970-01-01T00:00:00.00Z'),
updated_at=dateutil_parser('1970-01-01T00:00:00.00Z'),
created_at="created_at_example",
updated_at="updated_at_example",
) # TestCaseCreate |

# example passing only required values which don't have defaults set
Expand Down
12 changes: 12 additions & 0 deletions qaseio/docs/CreateResultsRequestV2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# CreateResultsRequestV2


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**results** | [**[CreateResultsRequestV2ResultsInner]**](CreateResultsRequestV2ResultsInner.md) | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


27 changes: 27 additions & 0 deletions qaseio/docs/CreateResultsRequestV2ResultsInner.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# CreateResultsRequestV2ResultsInner


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **str** | | [optional]
**title** | **str** | | [optional]
**signature** | **str** | | [optional]
**testops_id** | **int, none_type** | | [optional]
**case_id** | **int, none_type** | | [optional]
**suite_id** | **int, none_type** | | [optional]
**execution** | [**ResultExecution**](ResultExecution.md) | | [optional]
**fields** | **{str: (str,)}** | | [optional]
**attachments** | [**[ResultAttachment]**](ResultAttachment.md) | | [optional]
**steps** | [**[ResultStep]**](ResultStep.md) | | [optional]
**params** | **{str: (str,)}** | | [optional]
**author** | **str** | | [optional]
**relations** | [**ResultRelations**](ResultRelations.md) | | [optional]
**muted** | **bool** | | [optional]
**message** | **str** | | [optional]
**created_at** | **float, none_type** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


12 changes: 12 additions & 0 deletions qaseio/docs/RelationSuite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# RelationSuite


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**data** | [**[RelationSuiteItem]**](RelationSuiteItem.md) | |
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


13 changes: 13 additions & 0 deletions qaseio/docs/RelationSuiteItem.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# RelationSuiteItem


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**title** | **str** | |
**public_id** | **int, none_type** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


87 changes: 87 additions & 0 deletions qaseio/docs/ResultApi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
# qaseio.ResultApi

All URIs are relative to *https://api.qase.io/v1*

Method | HTTP request | Description
------------- | ------------- | -------------
[**create_results_v2**](ResultApi.md#create_results_v2) | **POST** /{project_code}/run/{run_id}/results |


# **create_results_v2**
> create_results_v2(project_code, run_id, create_results_request_v2)


### Example

* Api Key Authentication (TokenAuth):

```python
import time
import qaseio
from qaseio.api import result_api
from qaseio.model.create_results_request_v2 import CreateResultsRequestV2
from pprint import pprint
# Defining the host is optional and defaults to https://api.qase.io/v1
# See configuration.py for a list of all supported configuration parameters.
configuration = qaseio.Configuration(
host = "https://api.qase.io/v1"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: TokenAuth
configuration.api_key['TokenAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TokenAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with qaseio.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = result_api.ResultApi(api_client)
project_code = "project_code_example" # str |
run_id = 1 # int |
create_results_request_v2 = CreateResultsRequestV2(None) # CreateResultsRequestV2 |

# example passing only required values which don't have defaults set
try:
api_instance.create_results_v2(project_code, run_id, create_results_request_v2)
except qaseio.ApiException as e:
print("Exception when calling ResultApi->create_results_v2: %s\n" % e)
```


### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**project_code** | **str**| |
**run_id** | **int**| |
**create_results_request_v2** | [**CreateResultsRequestV2**](CreateResultsRequestV2.md)| |

### Return type

void (empty response body)

### Authorization

[TokenAuth](../README.md#TokenAuth)

### HTTP request headers

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


### HTTP response details

| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | OK | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

17 changes: 17 additions & 0 deletions qaseio/docs/ResultAttachment.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# ResultAttachment


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **str** | | [optional]
**file_name** | **str** | | [optional]
**mime_type** | **str** | | [optional]
**file_path** | **str** | | [optional]
**content** | **str** | | [optional]
**size** | **int** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


1 change: 1 addition & 0 deletions qaseio/docs/ResultCreate.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Name | Type | Description | Notes
**status** | **str** | |
**case_id** | **int** | | [optional]
**case** | [**ResultCreateCase**](ResultCreateCase.md) | | [optional]
**start_time** | **int, none_type** | | [optional]
**time** | **int, none_type** | | [optional]
**time_ms** | **int, none_type** | | [optional]
**defect** | **bool, none_type** | | [optional]
Expand Down
17 changes: 17 additions & 0 deletions qaseio/docs/ResultExecution.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# ResultExecution


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**start_time** | **float, none_type** | | [optional]
**end_time** | **float, none_type** | | [optional]
**status** | **str** | | [optional]
**duration** | **int, none_type** | | [optional]
**stacktrace** | **str** | | [optional]
**thread** | **str** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


12 changes: 12 additions & 0 deletions qaseio/docs/ResultRelations.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# ResultRelations


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**suite** | [**RelationSuite**](RelationSuite.md) | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


18 changes: 18 additions & 0 deletions qaseio/docs/ResultStep.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# ResultStep


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **str** | | [optional]
**step_type** | **str** | | [optional]
**data** | [**ResultStepData**](ResultStepData.md) | | [optional]
**parent_id** | **str** | | [optional]
**execution** | [**ResultStepExecution**](ResultStepExecution.md) | | [optional]
**attachments** | [**[ResultAttachment]**](ResultAttachment.md) | | [optional]
**steps** | [**[ResultStep]**](ResultStep.md) | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


13 changes: 13 additions & 0 deletions qaseio/docs/ResultStepData.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# ResultStepData


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**action** | **str** | | [optional]
**expected_result** | **str** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


15 changes: 15 additions & 0 deletions qaseio/docs/ResultStepExecution.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# ResultStepExecution


## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**start_time** | **float, none_type** | | [optional]
**end_time** | **float, none_type** | | [optional]
**status** | **str** | | [optional]
**duration** | **int, none_type** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


2 changes: 2 additions & 0 deletions qaseio/docs/ResultsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ with qaseio.ApiClient(configuration) as api_client:
severity="severity_example",
),
status="in_progress",
start_time=0,
time=0,
time_ms=0,
defect=True,
Expand Down Expand Up @@ -195,6 +196,7 @@ with qaseio.ApiClient(configuration) as api_client:
severity="severity_example",
),
status="in_progress",
start_time=0,
time=0,
time_ms=0,
defect=True,
Expand Down
4 changes: 2 additions & 2 deletions qaseio/docs/RunCreate.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ Name | Type | Description | Notes
**plan_id** | **int** | | [optional]
**tags** | **[str]** | | [optional]
**custom_field** | **{str: (str,)}** | A map of custom fields values (id => value) | [optional]
**start_time** | **datetime** | | [optional]
**end_time** | **datetime** | | [optional]
**start_time** | **str** | | [optional]
**end_time** | **str** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
Expand Down
Loading

0 comments on commit cc90d67

Please sign in to comment.