Variables
Capture a value from the screen with Store, or assign one with SET. The four right-hand sides SET accepts, and what it rejects.
Prerequisites
The mechanism
SET city = "Bangalore"
SET total = {{order.amount}}
SET cart = API.shopease_cart.response
SET item_count = API.shopease_cart.response.items.length
SET promo = screen(the promo banner headline on the home screen)#
Right-hand side
Example
Use when
SET random_city = ai(pick a random city in India).SET … = screen(...)
Part
Purpose
Example
Overwrites are permanent
Using and validating a stored value
A failed SET may not stop the test
Common mistakes
What you write
What happens
Next
Last updated
Was this helpful?