Frequently Asked Questions
How can I use the same flow when my apps have different app IDs?
If you want to run the same flow for apps with different app IDs, you can use an external parameter for appId
. Pass the parameter APP_ID
to Maestro:
And then refer to it in your flow using ${APP_ID}
:
How do I assert on a string that contains a dollar sign?
Values with dollar signs can be interpreted as variables. To avoid this, escape the dollar characters.
How do I compare two values?
To assert on values that exist on different screens, store them in variables.
How do I generate a random number?
Whilst there are commands for random strings and names, there's no function for generating random numbers. Users can use JavaScript to generate a number in the range they need.
randomNumber.js :
flow.yaml:
Why are my tests slower in Maestro's cloud environment?
The cloud environment optimises for reliability and repeatability, on the belief that slower correct results beat faster inconsistent results, every time. Each device, between one test and the next, is wiped and recreated, so that there's no chance of any test ever affecting any other. Compared with running locally, this adds 2-4 minutes between tests. To improve total time to finish a run, consider adding additional parallel runners. Another option is restructuring your tests for fewer longer tests, but be sure you're not making the same mistake, and sacrificing reliability or information in favour of speed.
Last updated
Was this helpful?