test-suite
2023.4
false
UiPath logo, featuring letters U and I in white
Test Suite User Guide
Automation CloudAutomation Cloud Public SectorAutomation SuiteStandalone
Last updated Aug 13, 2024

Testing a Package/Running a Test Set

Prerequisites:

  • Create a package, or Test Set.
  • Run the CLI exe (for Windows) or dll (for Linux) file.
  • Add the required Orchestrator API access application scopes.
  1. Run the test task, using uipcli test. You can see a list of the available sub-tasks.
  2. Specify the required parameters and run the run sub-task.

    See the list of parameters below.

    Parameter

    Description

    Orchestrator URL (pos. 0) (Required)

    The URL of the Orchestrator instance.

    Orchestrator Tenant (pos. 1)

    • (Required) for SaaP deployments.
    • (Optional) for PaaS deployments.

    The tenant inside which the package, or Test Set are.

    -u, or --username (Required if you use Basic Authentication, through a username and a password)

    The username used for authenticating to Orchestrator. You must pair it with the corresponding password.

    -p, or --password (Required if you use Basic Authentication, through a username and a password)

    The password used for authenticating to Orchestrator. You must pair it with the corresponding username.

    -t, or --token (Required if you use token-based authentication)

    The OAuth2 refresh token used for authenticating to Orchestrator. You must pair it with the Account Name and Client ID.

    -a, or --accountName (Required if you use token-based authentication)

    The Orchestrator CloudRPA account name. You must pair it with the OAuth2 refresh token and Client ID.

    -A, --accountForApp

    The Orchestrator CloudRPA account name(organization name). You must pair it with the Application ID, Application Secret, and Application scope for external application.

    -I, or --applicationId (Required if you use external application authentication)

    The external Application ID. You must pair it with the Application Account, Application Secret, and Application scope.

    -S, or --applicationSecret (Required if you use external application authentication)

    The external Application Secret. You must pair it with the Application Account, Application ID, and Application scope.

    --applicationScope (Required if you use external application authentication)

    The list of application scopes, separated by single spaces. You must pair it with the Application Account, Application ID, and Application Secret for external application

    -P, or --project-path

    The path to the Testing package file that you want to test.

    -s, or --testset
    The name shown for the Test Set you wish to execute. Ensure that the Test Set includes the most recent version of the Test Cases.
    If the Test Set isn't in the default folder, make sure to include the relevant folder name before it. For instance, use AccountingTeam\TestSet.

    --out

    The type of the result file <junit|uipath>.

    -r, or --result_path

    The destination path of the file where you want to store the results.

    -e, or --environment (Required for classic folders)
    The environment where you want to deploy the package. You must pair it with the project path.
    -w, or --timeout

    The time (in seconds) that you want to wait for the Test Set to execute. The default value is 7200 seconds.

    -i, or --input_path (Required if the entry-point workflow has input parameters that you want to pass through the command line)

    The full path to a JSON input file.

    --attachRobotLogs

    Attaches Robot Logs for each executed Test Case, and a JUnit Test Report.

    -o, or --organizationUnit

    The Orchestrator folder where you want to execute the Test Sets.

    -l, or --language

    The language used in the Orchestrator user interface.

    -y, or --disableTelemetry

    Disable telemetry data.

    --traceLevel

    Display the trace of the events.

    --identityURL (Required for PaaS deployments only)

    The URL of your identity server.

    --releaseNotes

    Add release notes.

    --disableBuiltInNugetFeeds

    Disable built in nuget feeds.

    --help

    Displays the parameters and examples for this command.

Examples:

  • test run "https://orch-23-10-paas.cloudapp.azure.com/" "TenantName" -u "orchestratorUsername" -p "********" -o "FolderName" --traceLevel Information -P "C:\userprofile\AutomationProjectWithTestCases\project.json"

  • test run "https://orch-23-10-paas.cloudapp.azure.com/" "TenantName" -I "76000552-3e4f-4590-9317-cdb420001f1d" -S "********" --applicationScope "OR.Folders OR.BackgroundTasks OR.TestSets OR.TestSetExecutions OR.TestSetSchedules OR.Settings.Read OR.Robots.Read OR.Machines.Read OR.Execution OR.Assets OR.Users.Read OR.Jobs OR.Monitoring" --identityUrl "https://orch-23-10-paas.cloudapp.azure.com/identity" -o "FolderName" --traceLevel Information -P "C:\userprofile\AutomationProjectWithTestCases\project.json"

  • test run "https://automation-suite.base.url.com/" "TenantName" -A "organizationName" -I "3f6239b9-e0e8-465e-a429-d9ffd1d9e57a" -S "********" --applicationScope "OR.Folders OR.BackgroundTasks OR.TestSets OR.TestSetExecutions OR.TestSetSchedules OR.Settings.Read OR.Robots.Read OR.Machines.Read OR.Execution OR.Assets OR.Users.Read OR.Jobs OR.Monitoring" -o "FolderName" --traceLevel Information -P "C:\userprofile\AutomationProjectWithTestCases\project.json"

  • test run "https://cloud.uipath.com/" "TenantName" -A "organizationName" -I "becc663c-8f1e-409a-a75f-c00330d80bc8" -S "********" --applicationScope "OR.Folders OR.BackgroundTasks OR.TestSets OR.TestSetExecutions OR.TestSetSchedules OR.Settings.Read OR.Robots.Read OR.Machines.Read OR.Execution OR.Assets OR.Users.Read OR.Jobs OR.Monitoring" -o "FolderName" --traceLevel Information -P "C:\userprofile\AutomationProjectWithTestCases\project.json

  • test run "https://orch-23-10-paas.cloudapp.azure.com/" "TenantName" -u "orchestratorUsername" -p "********" -o "FolderName" --traceLevel Information -P "C:\userprofile\AutomationProjectWithTestCases\project.json" --out junit

  • test run "https://orch-23-10-paas.cloudapp.azure.com/" "TenantName" -u "orchestratorUsername" -p "********" -o "FolderName" --traceLevel Information -P "C:\userprofile\AutomationProjectWithTestCases\project.json" --out uipath

Adding an External Application

To register an external application so that it can access your UiPath resources using OAuth:

  1. Log in to the tenant as an Administrator.
  2. Go to Tenant > Manage access > Assign roles and click Manage Accounts & Groups.

    The tenant-level opens.

  3. Along the left, select External Applications.

    The External Applications page opens, listing all the existing external applications registered for the current tenant:



  4. Above the table, on the right, click Add Application.
  5. Fill in the Application Name field.
  6. Select an option for Application Type.

    If you select Confidential application, you receive an app secret at the end, so make sure your application can store it securely. If it can't, select Non-confidential application.

  7. Under Resources, click Add Scopes.

    The Edit Resource panel opens on the right, where you can select the resources to which the application should have access.

  8. From the Resource drop-down list, select the UiPath API that the application can use.
    Note: You can only add scope for one resource at a time. If you want to allow access to multiple resources, repeat this process to add scope for each resource.
  9. On the User Scope(s) tab, select the check boxes for the logical API permissions that you want to grant, as needed.

    Granting permissions under user scope means that the external application can access those resources within a user context and a user with the appropriate permissions must be logged in.

  10. If this is a confidential application, you can switch to the Application Scope(s) tab to also grant application-level permissions for the selected resource, as needed.

    With permissions under application scope, the external application has access to application-wide data for the selected scopes without the need for user interaction.

    Non-confidential applications cannot access application scope.

  11. Click Save.

    The panel closes and the selected resource and scopes are added to the Resources table in the form.

  12. If the external application can accept it, you can add a URL in the Redirect URL field and the authorization response is sent there. The application can then use it to access UiPath resources.
  13. Click Add to create the registration.

    A confirmation message opens. For confidential applications, the confirmation message includes the app secret that the registered external application can use to request authorization. Make sure you save it in a secure location because you cannot see it again.

  • Adding an External Application

Was this page helpful?

Get The Help You Need
Learning RPA - Automation Courses
UiPath Community Forum
Uipath Logo White
Trust and Security
© 2005-2024 UiPath. All rights reserved.