This directory contains end-to-end (E2E) tests for the react-native-zip-archive playground apps (playground-expo and playground-rn). The Maestro flows live in .maestro/flows/ at the repo root.
We use Maestro for E2E testing because it:
- Requires minimal native setup
- Works with both iOS and Android
- Uses simple YAML-based test flows
- Handles React Native apps reliably
# macOS
curl -fsSL "https://get.maestro.mobile.dev" | bash
# Or via Homebrew
brew install maestroFor other platforms, see the Maestro installation guide.
-
Build the iOS app (Expo playground shown; for the bare RN app use
playground-rn/iosandPlaygroundRN):cd playground-expo/ios xcodebuild -workspace RNZipArchivePlayground.xcworkspace \ -scheme RNZipArchivePlayground \ -configuration Debug \ -sdk iphonesimulator \ -derivedDataPath build -
Install and launch the app on a simulator, then run Maestro:
maestro test .maestro/flows/
-
Build the Android app:
cd playground-expo/android ./gradlew :app:assembleDebug -
Install the APK and run Maestro:
adb install app/build/outputs/apk/debug/app-debug.apk maestro test .maestro/flows/
| Flow | Description |
|---|---|
home.yaml |
Verifies the home screen loads with all demo cards |
zip-and-unzip.yaml |
Tests zipping a sample folder and unzipping it |
list-contents.yaml |
Tests listContents, selective unzip(..., entries), and selective unzipWithPassword(..., entries) |
password.yaml |
Tests creating a password-protected zip and extracting it |
progress.yaml |
Tests subscribing to progress events during a large zip operation |
assets.yaml |
Tests unzipping a bundled archive via unzipAssets |
ci-master.yaml |
Full CI suite (home + zip + unzip + list/selective + password + progress + assets) |
Maestro flows are YAML files that describe user interactions. See the Maestro documentation for available commands.
Example:
appId: com.rnziparchive.playground.expo
---
- launchApp
- tapOn: "Zip Operations"
- tapOn: "Zip Sample Folder"
- assertVisible: "Success"Maestro can be integrated into GitHub Actions using the Maestro Cloud or by running the CLI directly on a macOS runner with simulators/emulators.