Parameters

This topic explains Tosca Cloud's parameter types and levels. Use parameters to control how tests run and reuse values across test cases, playlists, workspaces, and your entire tenant.

Parameter types

Tosca Cloud supports two parameter types, each set at different levels. Here's what each type does:

  • Special task parameters control how a test case runs. You set them and Tosca Cloud acts on them in the background. For example, define the default browser, set a wait time, or configure the decimal character format. You don't need to reference them in test steps. For a full list of special task parameters and their values, check out Supported parameters.

  • Custom parameters define a value once that you reuse in multiple test steps. For example, if you need to enter the same 20-digit code in several places, create one parameter and reference it everywhere. check out Parameter values.

Parameter levels

Set parameters at the following levels. Each level inherits the values from the level above and can override them. Set your defaults at the tenant level. Override only what needs to be different for a specific workspace, test case, or playlist, or for a folder or test case in a playlist.

Level

Set by

Applies to

Overrides

Tenant

Administrators

All workspaces, playlists, and test cases in this tenant.

None.

Workspace

Administrators and contributors

All playlists and test cases in this workspace.

Tenant values.

Test case

Administrators and contributors

This test case only.

Tenant and workspace values.

Playlist

Administrators and contributors

All test cases in this playlist.

Tenant, workspace, and test case values.

Folder

Administrators and contributors

All test cases in this folder.

Tenant, workspace, test case, and playlist values.

Test case in playlist

Administrators and contributors

This test case instance in this playlist only.

Tenant, workspace, test case, playlist, and folder values.

Choose the right level

Choose the level that matches the scope of the value you want to set:

  • Tenant: Use tenant parameters for values that should be the same across your entire organization. For example, the default browser, base URL, or number format. Every team gets a consistent starting point without extra configuration.

  • Workspace: Use workspace parameters when a team or project needs different values from the tenant defaults. For example, one team tests a localized version of the application with a different URL or decimal format. Workspace parameters override tenant values for that workspace only and don't affect other teams.

  • Test case: Use test case parameters for values that are specific to a single test case.

  • Playlist: Use playlist parameters to override values for one specific playlist. For example, if you want to run the same test cases against a staging environment instead of production, set the URL as a playlist parameter for that playlist.

  • Folder in playlist: Use folder parameters to override values for all test cases in a specific folder within a playlist. Folder parameters override playlist values for every test case in that folder.

  • Test case in playlist: Use test case in playlist parameters to override values for a single test case within a playlist, without changing the test case itself.

Parameter sets

Create parameter sets to group and reuse parameters and apply them across your test cases, playlists, and folders. If a parameter in a set shares a name with a tenant or workspace parameter, the set value takes priority.

Let's say your organization tests a travel booking application. The administrator sets the following tenant parameters:

  • Browser: All test cases use Chrome as the default browser. The data type is set to String.

  • BaseUrl: All test cases use https://booking.travelapp.example.com as the base URL. The data type is set to String.

A contributor sets the following workspace parameter for the team's workspace:

  • Browser: The workspace uses Firefox as the default browser, overriding the tenant value. The data type is set to String.

A contributor sets the following test case parameter on a test case that checks flight bookings:

  • FlightNumber: The test case uses TRV-2024-789. The data type is set to String.

A contributor sets the following playlist parameter to run the staging playlist:

  • BaseUrl: All test cases in this playlist use https://staging.travelapp.example.com. The data type is set to String.

A contributor sets the following folder parameter on the checkout folder inside that playlist:

  • BaseUrl: All test cases in the checkout folder use https://payment.staging.travelapp.example.com. The data type is set to String.

A contributor sets the following parameter on one specific test case inside the checkout folder:

  • PaymentMethod: This test case instance uses CreditCard. The data type is set to String.

When you run a test case, Tosca Cloud applies the parameters as follows:

  • Most test cases use https://staging.travelapp.example.com and Firefox because the playlist and workspace parameters override the tenant values.

  • The checkout folder uses https://payment.staging.travelapp.example.com because the folder parameter overrides the playlist value for all test cases in that folder.

  • The specific test case instance in the checkout folder uses CreditCard as the PaymentMethod because the test case in playlist parameter applies to that instance only.

What's next

Set up parameters at the right level for your use case: