Skip to content

Test Executions

Re-run a Test Execution

/api/v2/testexecutions/{id}/rerun 📋 Copied! ▼

Role: Standard and above.

Runs the failed Test Cases of the execution again.

Parameters

Name Description
id * Numeric ID of the Test Execution.
Type: integer (path)

Responses

Code Description
200

The re-run was started. The response is the ID of the new Test Execution.

Media type: application/json

Example Value:

{
"id": 0
}
404

Resource was not found.

500

The re-run could not be scheduled.

Get Test Execution

/api/v2/testexecutions/{id} 📋 Copied! ▼

Role: Guest and above.

Parameters

Name Description
id * Numeric ID of the Test Execution.
Type: integer (path)

Responses

Code Description
200

Test Execution data. directRun is true for a direct run of one Test Case (then testCase is set). In resultList, errorCode is one of SUCCESS, FAILURE, TIMEOUT, INTERNAL_BE_ERROR, DISABLED, INIT_FAILED, CANCELLED, TRC_VERIFICATION_FAILURE; initFailureInfo says which device failed to initialise and why. mcmTraceFiles links the MCM traces.

Media type: application/json

Example Value:

{
"id": 0,
"created": "string",
"start": "string",
"end": "string",
"testSuite": {
    "id": 0,
    "name": "string",
    "testCases": [
        {
            "id": 0,
            "name": "string",
            "description": "string",
            "testCaseMobileNames": [
                "string"
            ]
        }
    ]
},
"rerunTestExecutionId": 0,
"result": {
    "created": "string",
    "successRatio": "{ \"success\": 0, \"executed\": 0, \"disabled\": 0, \"total\": 0 }",
    "traceAvailable": false,
    "hasInitError": false,
    "resultList": [
        {
            "success": false,
            "errorCode": "FAILURE",
            "initFailureScope": "DEVICE",
            "initFailureInfo": {
                "deviceId": "string",
                "deviceName": "string",
                "testNodeName": "string",
                "failedFunction": "string",
                "errorId": "string",
                "errorMessage": "string"
            },
            "testCaseId": 0,
            "testCaseName": "string",
            "testCaseDescription": "string",
            "testCaseWeight": 1,
            "traceFile": "string",
            "logs": [
                {
                    "success": true,
                    "stepNumber": 1,
                    "mobileDeviceName": "string",
                    "description": "string",
                    "fileKey": "string",
                    "created": "string",
                    "logType": "string"
                }
            ],
            "mcmTraceFiles": [
                {
                    "mobileDeviceName": "string",
                    "mcmTraceUrl": "string"
                }
            ]
        }
    ]
},
"involvedTestNodes": [
    "string"
],
"directRun": false,
"testCase": {
    "id": 0,
    "name": "string"
}
}
404

Resource was not found.

Delete a Test Execution

/api/v2/testexecutions/{id} 📋 Copied! ▼

Role: Admin, or the user who created the Test Execution.

Parameters

Name Description
id * Numeric ID of the Test Execution.
Type: integer (path)

Responses

Code Description
200

Test Execution was deleted successfully.

404

Resource was not found.

List Test Executions's

/api/v2/testexecutions 📋 Copied! ▼

Role: Guest and above.

Parameters

Name Description
page Zero-based page number. Default 0.
Type: integer (query)
size Page size. Default 20.
Type: integer (query)
sort <field>,asc or <field>,desc.
Type: string (query)
prj Only return items assigned to these projects: comma-separated project IDs.
Type: string (query)
start Only executions created at or after this timestamp.
Type: string (query)
end Only executions created before this timestamp.
Type: string (query)
search Search text.
Type: string (query)
testSuiteId Only executions of this Test Suite.
Type: integer (query)

Responses

Code Description
200

A page of Test Executions. Use sort=created,desc for the newest first.

Media type: application/json

Example Value:

{
"content": [
    {
        "id": 0,
        "created": "string",
        "start": "string",
        "end": "string",
        "testSuite": {
            "id": 0,
            "name": "string"
        },
        "rerunTestExecutionId": 0,
        "result": {
            "created": "string",
            "successRatio": "{ \"success\": 0, \"executed\": 0, \"disabled\": 0, \"total\": 0 }",
            "traceAvailable": false,
            "hasInitError": false
        },
        "analysis": {
            "analysis": {
            },
            "status": "COMPLETE",
            "created": "string",
            "updated": "string"
        },
        "directRun": false,
        "testCase": null
    }
],
"totalElements": 0,
"totalPages": 0,
"number": 0,
"size": 20
}

Get stored analysis for a Test Execution

/api/v2/testexecutions/{id}/analysis 📋 Copied! ▼

Role: Guest and above.

Parameters

Name Description
id * Numeric ID of the Test Execution.
Type: integer (path)

Responses

Code Description
200

The stored AI analysis. status is ANALYZING, COMPLETE or FAILED; analysis is a JSON object that is filled when the analysis is complete.

Media type: application/json

Example Value:

{
"analysis": {
},
"status": "COMPLETE",
"created": "string",
"updated": "string"
}
404

The execution does not exist, or it has no analysis.

Trigger analysis of a Test Execution

/api/v2/testexecutions/{id}/analyze 📋 Copied! ▼

Role: Standard and above.

Parameters

Name Description
id * Numeric ID of the Test Execution.
Type: integer (path)

Responses

Code Description
202

Request accepted; the analysis runs asynchronously. The response has no body. Poll GET /api/v2/testexecutions/{id}/analysis for the result.

404

Resource was not found.

503

AI analysis is not available on this environment.

Delete the stored analysis of a Test Execution

/api/v2/testexecutions/{id}/analysis 📋 Copied! ▼

Role: Admin.

Removes the stored AI analysis, for example before analysing the execution again.

Parameters

Name Description
id * Numeric ID of the Test Execution.
Type: integer (path)

Responses

Code Description
204

Analysis was deleted successfully.

404

The execution does not exist, or it has no analysis.