verify-on-emulator
Boot (or reuse) the TBox-Mock-Play AVD, install the debug APK, drive the launcher, and capture screenshots to verify UI changes on the head-unit geometry.
Files3
View on GitHubSKILL.md.claude/skills/verify-on-emulator/SKILL.md
GitHubVerifying on the TBox-Mock-Play emulator
Visual verification on the head-unit geometry. $ARGUMENTS names the
screen or area to drive to and screenshot; with no argument, verify
the home dashboard.
Environment
- Tools: resolve
adb/emulatorfromPATHfirst (command -v adb; the Bash shell initializes from your profile — the committed allowlist covers bare invocations). If not onPATH, use$ANDROID_HOME/{platform-tools,emulator}, else the conventional SDK root (~/Library/Android/sdkon macOS,~/Android/Sdkon Linux); absolute-path invocations prompt unless mirrored in.claude/settings.local.json.local.propertiesand~/Librarymay be Read-denied — usels/adb, notcat. Gradle finds the SDK vialocal.propertiesregardless. - AVD:
TBox-Mock-Play— 1280x720 @ 160 dpi (the 800x480 dp head-unit geometry) with Google Play, so a signed-in account provides real calendar events and media sessions. The definition is committed in this skill directory:create-avd.shwrites the AVD registry files directly fromtbox-mock-play.config.ini(no avdmanager / cmdline-tools needed; only theandroid-33 google_apis_playstoresystem image for the host arch must be installed). Google sign-in inside the AVD stays a one-time manual step per machine — account state is not portable. - App id: the stable flavor is
io.github.seijikohara.femto(no debug suffix); nightly adds.nightly(io.github.seijikohara.femto.nightly). Only the stable flavor has a debug variant, so this skill always builds, installs, and grants permissions to the stable app id.
Procedure
Build the debug APK via the
verify-android-buildskill (the verification-procedure SSOT). The APK lands atapp/build/outputs/apk/stable/debug/app-stable-debug.apk.Reuse or boot the emulator. More than one emulator may be running, so resolve serials first:
adb devices, thenadb -s <serial> emu avd nameto identify each instance. If aTBox-Mock-Playis already up, reuse it — installing onto the instance the user is watching is the point; never touch an unrelated instance. If none is running:emulator -avd TBox-Mock-Play -no-audio -gpu hostWindowed on purpose — the user watches the verification live. In a headless context (no display available) add
-no-window -gpu swiftshader_indirectinstead of-gpu host. If the AVD does not exist (emulator -list-avds), create it first:.claude/skills/verify-on-emulator/create-avd.shWait until
adb -s <serial> shell getprop sys.boot_completedreports1before installing. With multiple devices attached, pass-s <serial>to every adb call below.Install the APK:
adb -s <serial> install -r app/build/outputs/apk/stable/debug/app-stable-debug.apkNote:
connectedStableDebugAndroidTestuninstalls the app afterward — run:app:installStableDebug(oradb install -r) again before manual screenshots. After a reinstall,am force-stop+ restart the app so the running process is the new code.Pre-grant runtime permissions — the startup permission dialog blocks the dashboard (
MainActivity.requestRuntimePermissions()pops a location dialog on first run; uiautomator showscom.google.android.permissioncontroller). Pre-grant to skip it:adb shell pm grant io.github.seijikohara.femto android.permission.{ACCESS_FINE_LOCATION,ACCESS_COARSE_LOCATION,READ_CALENDAR,READ_PHONE_STATE,BLUETOOTH_CONNECT}then
am force-stop+ restart.Drive the UI:
uiautomator dump /sdcard/ui.xml+adb pull, grepcontent-desc="Settings"for the dock button bounds (theDashboardDockcomponent, formerly called the footer), theninput tap. The settings ModalBottomSheet opens partially expanded —input swipeup to fully expand, then swipe to scroll.Capture and inspect: Compose row text often does not appear as discrete
text=nodes (merged semantics), so confirm with a screenshot —screencap -p+ pull + Read the image:adb shell screencap -p /sdcard/shot.png && adb pull /sdcard/shot.png
Notes and former limitations
- The LIVE map WebView renders on the emulator (verified 2026-07
under both
-gpu hostandswiftshader_indirect); the old "GL surface cannot present" limitation no longer reproduces. A blank map is NOT expected — check the-gpumode and logcat before suspecting a regression. - The Play system image has no
adb root; runtime grants viapm grantstill work.
Report
Report explicitly what was run and what was observed:
- "Ran
adb install -r app-stable-debug.apk— Success." - "Pre-granted permissions via
adb shell pm grant ...." - "Captured
shot.png— the calendar card renders the 6-day strip."
Do not claim the UI "looks right" generically; cite the commands and attach or describe the screenshots.