Repository navigation
feat: add --install-only and --pick-device to Appium runners - #65
Conversation
Builds, launches the device, resets, and installs the app, then exits without starting Appium or running tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Prompts for an iOS simulator and/or Android AVD in run-local.sh and, up front, in run-all.sh. Also lets --device override .env device names and syncs OS_VERSION with the running device. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
abdulraqeeb33
left a comment
There was a problem hiding this comment.
Nice addition, both flags are genuinely useful and the implementation follows the existing runner conventions closely. Two things worth a look before merge, neither blocking.
Also three minor notes:
run-local/runtime.sh:409— a failed version lookup and "version already matches" are both a silentreturn 0. Whenadb getproptimes out or the simctl/python read fails,versionis empty, the regex fails, andOS_VERSIONquietly stays at the default. That is the exact condition the function exists to prevent, and it surfaces later as a confusing AppiumplatformVersionmismatch rather than "couldn't read the device OS version". Worth splitting the empty-lookup case out with awarn.README.md:3— the intro still reads "builds the app, boots a simulator/emulator, starts Appium, resets app state, and runs the E2E test suite." With--install-onlythat is no longer the only path. The options table covers the flag, just the lead sentence that is stale.README.md:138-148— therun-all.shsection does not mention--pick-device, thoughrun-all.sh --helpdocuments it.
- Fail the device picker on EOF instead of looping - Make --device fully override .env on iOS (UDID, runtime) - Forward --install-only from run-all, one SDK per platform - Resolve the booted simulator instead of simctl's `booted` target - Warn when the device OS version can't be read - Extract ios_sim_version and combo_runs helpers Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks @abdulraqeeb33. Addressed the three notes in d99ae07: empty version lookup now warns, README intro mentions --install-only, and the run-all section shows --pick-device and --install-only. |
sherwinski
left a comment
There was a problem hiding this comment.
I noticed that the second fallback block in run-local/runtime.sh:82 still splices $IOS_SIMULATOR into Python source inside single quotes. The same quote-in-value failure applies as in #65 (comment). That code is outside the scope of this PR so probably worth addressing in a separate PR, or just make the update here.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks @sherwinski, fixed the fallback lookup here in 3897959, simulator name is passed as argv now. |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Description
Adds
--install-onlytorun-local.shand--pick-devicetorun-local.shandrun-all.sh, so you can install a demo app without running tests and choose which simulator or emulator to use.Details
--install-only: builds, launches the device, resets, and installs the app (adb/simctl/devicectl), then exits without starting Appium or running tests. It skips the Appium/vpx checks. With--skip-buildit reinstalls the existing artifact. It's not inrun-all.shbecause every demo has the bundle IDcom.onesignal.example, so each install would overwrite the last.--pick-device: shows a numbered list of iOS simulators (newest iOS first, iPhones first) or Android AVDs, with booted/running ones marked.run-local.shasks after the platform is chosen.run-all.shasks once up front, only for platforms that have SDKs to run (e.g.--sdks=iosonly asks for a simulator), and forwards--device(plus--udidon iOS) to each run.--device=NAMEnow overridesAVD_NAME/IOS_SIMULATORfrom.env.OS_VERSIONis reset to the running device's OS version, so Appium'splatformVersioncheck passes on a non-default device.Testing:
bash -nandvp checkpass. I tested the picker against local simulators and AVDs, tested the iOS OS version lookup, and testedrun-all.shasking only for the relevant platforms with--sdks=ios,android, andios,flutter. Not yet tested: a full test run on a picked device, and--install-onlyon a device.🤖 Generated with Claude Code