Global Variables
Last updated
Last updated
Enables the reusability of data across multiple scripts within the same project. If the data for a variable ever changes, updating it in “Global Variables” section will propagate that change across all the scripts that uses it.
Click on the Setup link in the navbar after navigating to the desired mobility project.
Click on the “Global Variables” tab on the left side panel to open the variables section.
Click on the “Add” button to add the variables.
Once the variable name, type and value(s) are entered, click on the “Save” button to create the variable which can be used across all scripts in the project. The variables can be edited simply by changing the value(s) in the text field(s) for a variable and clicking the “Save” button.
Use custom variable value.
Masks the value of the variable.
Provides a random integer value between the min and max values.
Provides a random decimal value between the min and max values with the number of digits after the decimal point based on the value in the “Decimal Point” field.
Generates a random UUID/GUID value. “Variable Value” field should be empty.
Can be used to store an email address that can be used across the project or can generate a random email based on the usage of question marks (?) and pound signs (#). i.e. ????####@gmail.com where the question marks will be replaced with a random letter from the English alphabet while the pound signs will be replaced with a random number between 0 and 9.
Generates a random date based on the format specified in the “Variable Value” field.
Generates a random date in the past based on the format specified in the date formatter field. The generated date would not go past the specified minimum year.
Generates a random date in the future based on the format specified in the date formatter field. The year in the generated date would be less than or equal to the maximum year.
Set a base URL for a variable that can be used across the project
Generates a random first name.
Generates a random last name.
*** Note: For the variable types that generate the random values, each instance of its usage will generate a random value. i.e. If 2 steps are using the last name variable type, for each step, a random last name will be generated. ***
Environment profiles can be used to create environment specific values for variables such that the same test script can be used to test multiple environments simply by selecting a different profile.
By default, variables are part of the “Global” environment.
*** Note: Duplicate variables in the target environment would be replaced with the values of the source environment. ***
*** Note: The default “Global” environment cannot be renamed nor deleted***
***Note: In order to prevent the variable value from being shown in the reports page, hide the data field of the step where the variable is being used. More information regarding this can be found . ***
Click on the “Create” icon above to make a new environment.
Click on the copy icon to clone variables from the current environment to a different one.
Click the edit icon to rename the name of an environment.
Click the garbage can icon to delete an environment.