Generic CI platform
Integrate Maestro Cloud with any CI/CD provider using the CLI. Works with Jenkins, GitLab CI, Azure DevOps, and more.
You can run Maestro Flows in the cloud from any CI platform by using the Maestro CLI. This flexible approach works with Jenkins, GitLab CI, Azure DevOps, and more.
Prerequisites
API Key: Get your API Key in the Maestro Dashboard.
Project ID: Obtain your Project ID from your project settings in the dashboard.
Build Compatibility:
Android: APKs must be ARMv8 compatible.
iOS: Simulator builds must be provided as a
*.appdirectory or a zipped*.app.
Integration steps
Organize your Flows
Add your Flow files to a single directory in your repository.
<root>
├── e2e/
│ ├── subflows/
│ │ └── LoginSubflow.yaml
│ ├── Login.yaml
│ └── Search.yamlIn this configuration, files in the root of e2e run as top-level Flows. Files in subdirectories can be used as subflows that are not executed, but can be used by other flows at the top level.
Install the Maestro CLI
Ensure the Maestro CLI is installed on your CI runner:
curl -Ls "https://get.maestro.mobile.dev" | bashRun the cloud command
Execute the maestro cloud command as part of your pipeline.
maestro cloud \
--api-key "<YOUR_API_KEY>" \
--project-id "<YOUR_PROJECT_ID>" \
--name "<uploadName>" \
--app-file "<APP_FILE>" \
--flows "./e2e"The following table describes all the parameter you must pass:
--api-key
Your Maestro Cloud API Key.
--project-id
Your Maestro Project ID.
--name
(Optional) A custom name for this specific upload.
--app-file
Path to your .apk or .app binary. Check the Build your app for the cloud guide for more information on how to build the app.
--flows
The directory containing your Flows.
Handling results
Once your tests finish running, Maestro follows standard CI practices to let you know how they went:
Exit Codes: The
maestro cloudcommand returns0on success and1if any Flow fails. CI platforms typically use these exit codes to mark a build as failed.Reports: A link to the upload details in the Maestro Console is printed in the terminal logs for every run.
Next steps
Now that your CI pipeline is connected, consider optimizing your cloud runs:
Configure the operating system for your runs to match your application and dependency requirements.
Define locales and time zones to ensure consistent behavior across environments and regions.
Explore all the subcommand options for
claud.
Last updated