Test Suites & Reports
Last updated
Was this helpful?
Last updated
Was this helpful?
Maestro can run a suite of tests and generate a test report at the end.
To run a suite, point maestro test
to a folder that contains the Flows
Maestro will run every flow from the directory excluding subfolders. The command will complete successfully if and only if all the Flows have been completed successfully.
To generate a report, add a --format
parameter to a test
command:
Or, if you are using Robin:
Once execution completes, the report will be stored in a report.xml
file in a JUnit-compatible format that is supported by most platforms.
junit
- JUnit XML format
html
- HTML format
--output {file}
allows to override the report filename
There are multiple mechanisms to control what Flows to run when running a test suite.
Flow tags are covered extensively in the following section:
By default, when running a test suite, only Flows from the top level of a given directory will be executed. Consider the following folder structure:
When running a test
or cloud
command on a workspace
folder, only flowA.yaml
will be executed by default (though it is still able to refer to subFolder/flowB.yaml
and subFolder/subSubFolder/flowC.yaml
using runFlow
command).
This behaviour can be customised by using inclusion patterns. To do that, update your config.yaml
(create the file if missing) as follows:
In such case, both flowA and flowB will be included in the test suite but not flowC.
Tests can also be included recursively:
In this example, all Flows A, B, and C will be included in the test suite.
To run your Flows in a given order, you can add the following configuration to your config.yaml
file:
This configuration describes to Maestro the order of the Flows you want to run. The list accepts either the Flow file names (without the .yaml
extension) or the Flow name.
The continueOnFailure
flag determines whether Maestro should proceed with the execution of subsequent Flows defined in the sequence if a previous one fails. As an example: if flowA
fails and continueOnFailure
is true
, flowB
will be executed. If the flag is false
, flowB
won't be executed. Note that Flows that are not defined in executionOrder
will not be impacted and will always be run after the sequential Flows, irrespective of this Flow.
Note that your Flows should not depend on device state and should be treated as isolated, even though they run in sequence. A good rule of thumb is to ensure that each Flow can be run on a completely reset device.
For instance, if you have three Flows, flowA
, flowB
, and flowC
, but you want to run only flowA
and flowB
sequentially, don't add flowC
and flowD
to the list. Maestro will run these Flows in non-deterministic ordering after the Flow sequence has finished executing.
This is an experimental feature powered by LLM technology. All feedback is welcome.
Maestro introduces a new feature that leverages AI to analyze your end-to-end (E2E) mobile tests and provide actionable insights based on your test logs, commands, and screenshots captured during your test runs. The AI-powered analysis identifies potential issues in your app's functionality, UI, and internationalization, helping you improve app quality efficiently.
Login Requirement: Before you use the AI analysis feature, ensure you are logged into Maestro. Run the following command:
Analyzing your tests: To analyze your test flows with AI, use the --analyze flag with the maestro test command:
While we aim for precision, please note that this is a beta release, and the results should be validated before making critical decision
This will enable AI analysis and provide a detailed report based on your test artifacts:
Examples
Successful Analysis
Command:
Output:
No Issues Found
If no issues are detected, you will see a message like this:
Disabling Notifications
To disable the AI analysis notification, set the MAESTRO_CLI_ANALYSIS_NOTIFICATION_DISABLED
environment variable to true before running Maestro:
Feedback
The Analyze feature is currently in Beta. Share your feedback and suggestions in our Slack channel: #community-chat