| name | verify |
| description | Build, install, and drive the scripta sandbox app on an Android emulator/device to verify editor changes by observing rendering and behavior. |
Verifying scripta (self-drawn Compose code editor)
The editor is a library (editor/, KMP: android + jvm "desktop"). The runnable
surface is the Android sandbox app (sandbox/). Desktop has no app entry point
and (v1) no text input, so device verification = the Android sandbox.
Build + install + launch
./gradlew.bat :sandbox:assembleDebug
APK=sandbox/build/outputs/apk/debug/sandbox-debug.apk
adb -s <serial> install -r "$APK"
adb -s <serial> shell am force-stop top.yukonga.scripta
adb -s <serial> shell am start -n top.yukonga.scripta/.sandbox.MainActivity
Package top.yukonga.scripta, activity .sandbox.MainActivity.
Sandbox UI (top toolbar, leftâright): ć 蜜 3MB YAML (loads ~240k lines / 60k
entries â the perf smoke test), æąèĄ: ć
ł/ćŒ (soft-wrap toggle), ćȘèŻ»: ć
ł/ćŒ
(read-only toggle). Below is the editor.
Screenshot
Drive it
adb -s <s> shell input tap <x> <y>
adb -s <s> shell input swipe <x> <y> <x> <y> 700
adb -s <s> shell input swipe 450 2000 450 300 90
adb -s <s> shell input swipe 450 1700 450 500 2500
adb -s <s> shell input keyevent 66
Hit-test check (highest-value for scroll/geometry changes): scroll deep, long-press a
known word, confirm the selection highlight lands on exactly that word+line.
Read-only check: toggle ćȘèŻ»:ćŒ â caret disappears, typing/paste blocked, but
long-press still selects. Edit check: place caret, ENTER â line numbers renumber
(proves recomposition-on-edit still fires).
Rough perf (frame time)
adb -s <s> shell dumpsys gfxinfo top.yukonga.scripta reset
adb -s <s> shell dumpsys gfxinfo top.yukonga.scripta | grep -E "Total frames|percentile"
Caveat: the emulator is GPU-bound (50th ~20-30ms), so it underrepresents
recomposition (CPU) savings. Fling frame counts vary with input registration â reset
- re-run for A/B, and compare tail (90th/99th) percentiles, not just the median.
Gotchas
- No Compose UI test harness wired up (
withHostTest {} not enabled); commonTest is
pure logic only. Device verification is the only runtime check for the @Composable.
- Real device may be locked (secure keyguard) â adb can't unlock; ask the user.
am start may land the app paused if the screen was asleep; input keyevent KEYCODE_WAKEUP first.