🔍 Testing
Sherlo Commands
Select a Sherlo command based on your testing needs:
- Local Builds
- Expo Update 🚀
- Expo Cloud Builds
Features
- ✅ Tests builds stored locally
- ⚠️ Requires new builds for each test run
Requirements
- Define paths to Preview Simulator Builds (Android and/or iOS)
Options
Option | Value | Description |
---|---|---|
--android | <path> | Path to Android build (.apk ) |
--ios | <path> | Path to iOS build (.app , .tar.gz or .tar ) |
Options --android
and --ios
override Config properties if are set in both places
Usage
Run Sherlo to test builds stored locally:
npx sherlo local-builds
Features
- ✅ Tests builds stored locally
- ✅ Requires new builds only when native code changes
- ✅ Works with over-the-air updates, making it super fast 🚀
Requirements
- Install
expo
version 51 or higher andexpo-dev-client
- Use EAS Update for over-the-air updates
Define paths to Development Simulator Builds (Android and/or iOS)
infoPaths to builds are required only when running the first test and when native code changes
Otherwise, Sherlo reuses the last uploaded builds
Options
Option | Value | Description |
---|---|---|
--branch | <branch> | Name of the EAS Update branch to fetch the latest update from |
--android | <path> | Path to Android build (.apk ) |
--ios | <path> | Path to iOS build (.app , .tar.gz or .tar ) |
Options --android
and --ios
override Config properties if are set in both places
Usage
Run Sherlo to test the latest update from an EAS Update branch:
npx sherlo expo-update --branch <branch>
Make sure you've published your latest changes to EAS Update before testing. You can use:
npx eas-cli update --auto --branch <branch>
Features
- ✅ Tests builds after completion on Expo servers
- ⚠️ Requires new builds for each test run
Requirements
- Use EAS Build to create Preview Simulator Builds on Expo servers
Add
eas-build-on-complete
script to yourpackage.json
:package.json{
"scripts": {
"eas-build-on-complete": "sherlo eas-build-on-complete --profile <profile>",
// ...
},
// ...
}EAS Build ProfileThe
--profile
option must:- Match the
--profile
option used in your EAS build command - Point to the EAS build profile that creates Preview Simulator Builds
- Match the
Options
Option | Value | Description |
---|---|---|
--easBuildScriptName | <name> | Name of the package.json script that triggers EAS build |
--waitForEasBuild | Start waiting for EAS build to be triggered manually |
Usage
Run Sherlo to test builds after completion on Expo servers:
Automatic EAS Build
Start Sherlo and automatically trigger the EAS build using a script from your
package.json
:npx sherlo expo-cloud-builds --easBuildScriptName <name>
Manual EAS Build
Start Sherlo and then manually trigger the EAS build command:
npx sherlo expo-cloud-builds --waitForEasBuild
The --profile
option in EAS build command must match the one in eas-build-on-complete
script
Common Options
These options work with any Sherlo command:
Option | Value | Default | Description |
---|---|---|---|
--token | <token> | Authentication token for the project | |
--config | <path> | sherlo.config.json | Path to the config file |
--projectRoot | <path> | . | Path to the root directory of your project |
Option --token
overrides Config property if is set in both places
Run Tests
Before running your tests, make sure you have:
- ☑️ completed the Setup
- ☑️ created the Config file
- ☑️ created the Builds (or set up EAS build command for Expo Cloud Builds)
Now run your chosen Sherlo Command and start testing!
Review Results
Once the tests are complete, you can review the results in the Sherlo web application
And that's it! 🎉
Enjoy testing with Sherlo 🥳