quiesco test
against it, on a macOS worker with an iOS simulator and on a Linux worker with an Android emulator. No Mac
or emulator of your own is needed.
The setup below runs the tutorial app’s tests (examples/todo-tutorial-vitest)
on both platforms. It needs the EAS CLI (npm install -g eas-cli), an Expo account (eas login) and the
project linked to it (eas init).
The build profile
Add ane2e profile to eas.json:
eas.json
EXPO_PUBLIC_QUIESCO=1is whatquiesco buildsets locally: the agent stays in the JS bundle and@quiesco/expo-pluginlinks@quiesco/nativeand allows the connection to the test host. Without it the build is a production build and Quiesco cannot connect to the app.ios.simulatormakes a simulator build (.app),android.buildType: "apk"an APK that can be installed on an emulator. Neither needs signing credentials (withoutCredentials).- The profile has no
developmentClient: the JS is bundled into the app, so the run needs no Metro.
The config
The local setup launches a dev client that loads its JS from Metro; the EAS build is a standalone app. EAS setsEAS_BUILD on its workers, so quiesco.config.mts can tell the two apart:
quiesco.config.mts
devClient Quiesco launches the app directly and starts no Metro. Pick a simulator the worker’s
image has (xcrun simctl list devices available in a workflow step lists them).
The workflow
.eas/workflows/e2e.yml
- Workers. The iOS simulator needs a
macos-*worker, the Android emulator alinux-*-nested-virtualizationone (the others have no KVM). - Node.js 24. Quiesco needs Node.js 24 or later; the workers’ default is older.
nvm install 24switches inside the step that runs Quiesco: eachrunis a shell of its own, so the switch does not carry over to the next step.eas/install_node_modulescan stay on the default Node. - The build.
eas/download_buildunpacks the iOS simulator build (EAS stores it as a.tar.gz), soartifact_pathis the.appon iOS and the.apkon Android. The step copies it to wherebinaryPathpoints. - The Android emulator. Linux workers have no display, so the workflow starts the emulator itself with
-no-windowand waits for the boot; Quiesco then uses the running emulator. The worker image has the system images under$ANDROID_HOME/system-images(Android 30 to 37 at the time of writing).avdmanagerprintsdevices.xmlerrors on these images; they are harmless, which is why its output is discarded. - The iOS simulator. Quiesco boots the simulator named in
devices.iositself. The first test of a job takes about a minute and a half longer: the simulator boots, and Quiesco’s system UI runner is built once for the worker’s Xcode. - Evidence. A failing test leaves its screenshot, element tree and logs under
artifacts/(artifacts);eas/upload_artifactattaches them to the job on the EAS dashboard.if: ${{ always() }}runs it after a failure too, andignore_errorkeeps a run where every test passed (andartifacts/was never created) from failing on the upload.
pull_request trigger runs it on every pull request once the Expo project is linked to the GitHub
repository (project settings on expo.dev). See Expo’s workflow syntax
for other triggers.
Release builds after the tests
The workflow above stops at the tests. To build the release only once they pass, add release build jobs that list the test jobs inneeds: EAS starts a job only when every job in its needs succeeded, so a
failed test leaves the release builds skipped and spends no build on them.
Put them in a workflow of their own that runs where releases come from, e.g. pushes to main, and keep
e2e.yml for pull requests. The jobs before the release builds are those of e2e.yml:
.eas/workflows/release.yml
test_* failed and build_release_* skipped. To send the release to
the stores as well, add a submit job with needs: [build_release_ios] (and the Android one); it needs
the store credentials set up in EAS (Expo’s pre-packaged jobs).
The release build is a build of its own from the same commit, without EXPO_PUBLIC_QUIESCO: the tests
ran the e2e build of that code, not the release binary. What differs between the two is the next
section.
Production builds
Quiesco is a gray-box tool: the e2e build carries an agent and a native module that a release must not. On EAS the two are separate builds of the same source, andEXPO_PUBLIC_QUIESCO alone decides which is
which:
EAS bundles the JS and, for a project without committed
ios/ / android/ directories, runs
expo prebuild in every build with that profile’s env, so both switches follow the profile. A build of
the tutorial app without the variable on EAS (simulator .app and release APK) contains none of the agent’s
and @quiesco/native’s markers that scripts/check-prod-strip.mjs scans for; the e2e build contains all
of them.
What can let Quiesco into a release:
- The variable set somewhere else. Set
EXPO_PUBLIC_QUIESCOonly in thee2eprofile: not in a committed.envfile (Expo loadsEXPO_PUBLIC_*from it into every build), not as an EAS environment variable of an environment your release builds use, and not in a profile that release profilesextends. - Committed native directories. When
ios/orandroid/is in the repository, EAS does not runexpo prebuildand the config plugin does not run either: whether@quiesco/nativeis linked is what the committed Podfile andsettings.gradlesay, for every profile. Keep the native directories generated (CNG), or check what the committed ones link. - EAS Update. An update is bundled like a build: publish it without the variable. Give the
e2eprofile nochannel, so an e2e build never downloads a release update (whose stub would cut the connection to Quiesco).
An EAS build on another machine
Thee2e build also runs outside EAS, e.g. on your Mac or in another CI:
apps.ios.binaryPath (or apps.android.binaryPath) points and leave devClient
out, as in the config above.