Subscribe

UiPath Studio

The UiPath Studio Guide

Application Testing

Studio Pro supports the creation of specialized test cases for conducting automated application testing. Individual test automation projects can be created in Studio Pro, used for verifying data, and included in CI/CD pipeline scenarios.

Application testing can be performed with Test Cases and Data Driven Test Cases, sequences that make use of verification activities part of the UiPath.Testing.Activities pack, together with activities from other packages.

Data Driven Test Cases use data imported as arguments into the project to verify test case execution. The entire data or only certain values may be used at execution.

Test automation projects may contain several test cases with linear execution, as activities are organized in sequences, this type of project has multiple entry points. There is no main workflow file and execution is performed per test case unless other .xaml files are invoked.

With Studio Pro, workflows can be converted into test cases or imported as test cases from other projects. Later, application testing projects may be published to Orchestrator, managed and executed from the Test Cases page.

Test Cases

Use the Test Automation project type from Backstage view > Start to start designing a test case.

563

Several such .xaml files can be added to a project by using the New > Test Case ribbon option.

The default activities packages for this type of project are: UiPath.System.Activities, UiPath.UIAutomation.Activities, and verification activities from the UiPath.Testing.Activities.

Verification activities such as Verify Control Attribute, Verify Expression, and Verify Expression with Operator are used for testing the data used by your workflows.

Such activities behave differently when executed or debugged. If a verification activity encounters an error, the execution does not stop to throw the error, but rather logs the failed activity in the Output panel. If the activity was executed successfully, it is marked in the panel.

923

Data Driven Test Cases

Application testing can require working with large data sets to verify the workflow execution and cover corner cases. Rather than creating multiple test cases for each data set, import and use your data sets inside the project with the Data Driven Test Case file type.

Go to the ribbon New > Data Driven Test Case. Add a name to this .xaml file and the Import Data Variation Source window opens.

814

Select a .xlsx, .xlsm Excel file to import, and pick a sheet. After the selection is made, click Import.

The imported Excel file is accepted as input, data is imported as InArgument types together with values from the file.

1801

Another way to import data is by right-clicking the test case in the project tree and selecting the Add Test Data context menu option.

495

As a next step, you can use the Verify Expression with Operator activity to compare values with those from the imported Excel file, using available operators. Read more about this activity here.

Run/Debug with Data Variations

Executing or debugging a Data Driven Test Case can be done in two ways, either by using all the imported data or discretionary by selecting the specific data to use.

Click the Run file with data variations or Debug file with data variations options from the ribbon. The Data variations window opens:

915

Select the data you would like to use for running or debugging the test case by clicking the checkbox next to each row. Click Run or Debug after the selection is made.

If the test case project uses the Verify Expression with Operator activity, the execution is performed once for each selected data set.

📘

Note:

If changes were made to the Excel data set, remove and add the data set again in the test case project.

Remove Test Data

Imported data sets can be removed from a Data Driven Test Case file by right-clicking the .xaml file in the Project panel and selecting Remove Test Data:

442

A new data set can be added by selecting the Add Test Data option.

Test Case Migration

Existing workflows used for testing purposes can be converted to and from test cases using Studio Pro. In addition, you can create an RPA Testing project from existing processes.

Convert to Test Case

To convert workflows into test cases right-click the files in the Project panel and select Convert to Test Case:

434

Import Test Cases

If you already created workflows or test cases, you can import them in your current project by right-clicking the project node, and selecting Import Test Cases:

472

Imported .xaml files are added to the project tree, as draft test cases.

Publish Test Cases

Test Case and Data Driven Test Case files are created as drafts by default. Before attempting to publish, these .xaml files need to be set as publishable from the Project panel.

508

Multi-select is available, simply hold the Ctrl key while selecting each file individually, then right-click > Set as Publishable.

325

📘

Note:

Publishable test cases can be set back to draft by right-clicking the test case and selecting Set as Draft.

After selecting Set as Publishable, the file's icon turns from gray to blue indicating that the file is ready to be published and packaged in a .nupkg file.

📘

Note:

Unless set to publishable, draft files are not packaged and published.

Publishing test cases is performed in a similar way as for other types of projects. Use the Publish option from the Studio Pro ribbon. You can set a version of the project and use the Certificate Signing options, read more about publishing projects here.

Test cases can be published to Orchestrator, Robot defaults, or a custom path. If you wish to publish to Orchestrator, make sure your Robot or UiPath Assistant is connected to Orchestrator, follow the steps here.

Updated 2 years ago


Application Testing


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.