Run an automation test using Azure DevOps

Learn how to run an automation test using Azure DevOps.

Before you start

You’ll need to complete the following:

Add the task to your YAML file

In your Azure DevOps project, select Pipelines.

Select Pipelines tab on Azure DevOps

Select your release pipeline.

Select your release pipeline

Select Edit.

Select Edit on New release pipelines

The Kobiton Automation Test Executor task will be added to your YAML file where your cursor is currently located. Move your cursor to the location where you’d like to add the task.

In the Tasks pane, search for and select Kobiton Automation Test Executor.

Select Kobiton Automation Test Executor

Use the following table to configure the task:

Parameter Required Environment Variable(s) Description

Display name

Yes

N/A

The release pipeline’s display name.

Kobiton API credentials

Yes

KOBITON_USERNAME
KOBITON_API_KEY

Your Kobiton API credentials.

Kobiton executor server credentials

Yes

N/A

Your Kobiton executor server credentials.

Git repository URL

Yes

N/A

The URL for your project’s cloud repository.

Git repository branch

Yes

N/A

The release branch for your project’s cloud repository.

Git repository SSH key

Yes

N/A

The SSH key for your project’s cloud repository.

Upload New App Version

No

KOBITON_SESSION_APPLICATION

Upload and install a new version of an existing app during the test session. If selected, enter the following:

  • App file path: the path from your project root to your .apk or .ipa file.

  • App ID: your app’s Kobiton App ID. Assigned to the KOBITON_SESSION_APPLICATION environment variable.

App ID/URL

No

KOBITON_SESSION_APPLICATION

Your app’s Kobiton App ID. Requires Upload New App Version to be unchecked.

Use Custom Device

No

KOBITON_DEVICE_NAME
KOBITON_SESSION_PLATFORM_VERSION
KOBITON_DEVICE_PLATFORM_NAME

Use a specific device from your devices. If selected, enter the following:

  • Kobiton Cloud Device Name: the device’s name in Kobiton. Assigned to the KOBITON_DEVICE_NAME environment variable.

  • Device platform version: the device’s platform version. Assigned to the KOBITON_SESSION_PLATFORM_VERSION environment variable.

  • Device platform: the device’s platform version, either Android or iOS. Assigned to the KOBITON_DEVICE_PLATFORM_NAME environment variable.

Root directory

No

N/A

Description

Commands

Yes

N/A

The command(s) to install project dependencies and run your test script.

Wait for execution

No

N/A

Wait for your automation script(s) to finish before starting the release pipeline. If selected, choose the following:

  • Log type: choose Combined to display all logs, or Separated to display either output or error logs only.

  • Terminate release pipeline on failed job: terminate the pipeline if the automation script fails.

When you’re finished, select Add.

Add Kobiton Automation Test Executor to azure

Verify the task has been added to the correct location in your YAML file, then select Save.

Choose to commit directly to your main branch or create a new branch, then select Save.

Run your automation test

In your Azure DevOps project, select Pipelines.

Select Pipelines tab on Azure DevOps

Select your release pipeline.

Select your release pipeline

Select Run pipeline to start your automation test.