Run Test Bot
Run test bot with JWT-based authentication for CI/CD pipelines
jwtToken (required)
JWT token for authentication. The token must contain:
organizationId - Organization identifier (required)
assetServiceApiUrl - Base API URL (required, used to construct service endpoint)
userId - User identifier for execution attribution (optional, falls back to support user)
projectId - Project identifier (optional)
testBotConfiguration (required)
Stringified JSON configuration for the test bot:
{
"testBotId": "string (required)",
"name": "string (optional)",
"executionConfiguration": {
"browser": "string",
"browserVersion": "string",
"closeBrowserAfterEachExecution": "boolean",
"customProperties": [
{
"customPropertyId": "string",
"name": "string",
"value": "string"
}
],
"type": "string",
"gridId": "string",
"excludeToBeRepairedTest": "boolean",
"gridUrl": "string",
"gridUrlForExecution": "string",
"osType": "string",
"resolution": "string",
"screenshotAfterEachStep": "boolean",
"screenshotOnError": "boolean",
"screenshotOnFinish": "boolean",
"timeout": "number",
"waitForElementTimeout": "number"
}
}
Example Usage
- task: runTestBot@1.3.0
inputs:
jwtToken: '$(JWT_TOKEN)'
testBotConfiguration: '{"testBotId":"6d3879da-5bde-47d3-99c4-8639f0ce6e4a","name":"API Validation Test Bot"}'
How It Works
- The task extracts
organizationId, userId, and base API URL from the JWT token
- Constructs the API endpoint:
{baseUrl}/test-bot-executor-services/rest/api/testops/{testBotId}/execute
- Sends the execution request with JWT authentication
- Polls for execution status every 5 seconds
- Retrieves and displays detailed results when execution completes
- Sets task result based on test bot execution outcome