Skip to main content
No Result Found
Connect & Get help from fellow developers on our Discord community. Ask the CommunityAsk the Community

Variables

Learn how to use local and global variables in App Low Code Automation to reuse test data across multiple steps, making your tests flexible and easy to maintain.

Variables make your tests flexible, readable, and easy to maintain. There are two types of variables in App Low Code Automation:

  • Local variables are used within a single test.
  • Global variables can be used across any test in your project.

Use variables to eliminate hardcoded values, centralize data, and make your tests easier to update.

Sample use case: Suppose you want to test login functionality across multiple test cases. Instead of hardcoding the password or email in every test step, you can create a variable called email and another called password. Reference these variables in your test steps, so you only need to update the value in one place if it changes. This makes your tests easier to maintain and reduces errors from inconsistent data.

Create a local variable

Local variables let you reuse values within the same test.

To create a local variable:

  1. Enter Set in the test step. The Set variable name to variable value command appears in the test editor. Click the command to proceed. Set variable value using the command in test editor
  2. In the Create a variable dialog, enter the variable name and the variable value. Create variable dialog showing name and value assignment

In the below example, the email address user@example.com is stored in the Email variable and the password 123abc is stored in the Password variable. Set variable value using the command in test editor

You can now reference this variable in other steps within the same test.

Deleting the original instance where the variable was created deletes the local variable from App Low Code Automation.

Create a global variable

Global variables help you share data across multiple tests and modules.

You cannot create global variables in the test editor. You can only create them in the Global variables section on the App Low Code Automation dashboard.

To create a global variable:

  1. Go to the Global variables section in the sidebar. Global variables section in sidebar for variable creation
  2. Click + Create global variable.
  3. Enter a name and value for the variable.
  4. Save the variable. You can now use it in any tests within App Low Code Automation.

Manage global variables

In the Global variables section, you see a list of all global variables. In the USED IN column, you can see how many tests use each global variable.

List of global variables with USED IN column in App Low Code Automation

To delete a global variable, click the ︙ icon next to it, then click Delete. In the dialog, click Delete again to confirm.

Delete global variable dialog in App Low Code Automation

Import variables into a test

You can import both local and global variables into your test steps:

  1. In the test editor, type the Type command and then type @ at the location where you want to use a variable. The editor displays a dropdown with available local and global variables, including their names and values. The dropdown is visually grouped by LOCAL VARIABLES and GLOBAL VARIABLES, making it easy to distinguish between them. Dropdown showing available local and global variables in test editor
  2. Select the variable from the list. The selected variable is inserted into your test step, allowing you to reuse data and keep your tests maintainable.

Variables help you centralize and manage data, making your tests easier to update and maintain. For more details, refer to the documentation or reach out to support.

We're sorry to hear that. Please share your feedback so we can do better

Contact our Support team for immediate help while we work on improving our docs.

We're continuously improving our docs. We'd love to know what you liked





Thank you for your valuable feedback

Is this page helping you?

Yes
No

We're sorry to hear that. Please share your feedback so we can do better

Contact our Support team for immediate help while we work on improving our docs.

We're continuously improving our docs. We'd love to know what you liked





Thank you for your valuable feedback!

Talk to an Expert
Download Copy Check Circle