flutter-device-smoke-test
Installation
SKILL.md
Flutter device smoke test
Verify a Flutter app works on a real Android device, producing an evidence line for each claim — a command whose output proves the step happened (a pid, a file, a clean logcat). No assertion without its evidence line.
Steps
- Connect.
adb devices -lto list; for a wireless device useadb connect <ip>:<port>. Completion: your device serial appears andadb -s <serial> get-stateprintsdevice. - Install the APK.
adb -s <serial> install -r build/app/outputs/flutter-apk/app-debug.apk. Completion: output containsSuccess. A 150MB debug APK over wifi takes minutes — give the command a 300s timeout. - Launch.
adb -s <serial> shell am start -n <packageId>/.MainActivity, wait ~5s. Completion:adb -s <serial> shell pidof <packageId>returns a pid. - Check for crashes.
adb -s <serial> logcat -d | grep -E 'E/flutter|FATAL|AndroidRuntime|Unhandled|LateInitialization|sqlite' | tail -20. Completion: noFATAL/AndroidRuntime/E/flutterlines from your app (ignore other apps' sqlite logs — scope by package or filter them out). - Verify the UI rendered. Screenshot:
adb -s <serial> exec-out screencap -p > /tmp/app.png; confirmfile /tmp/app.pngreports a PNG with device resolution. Note:uiautomator dumpshows no text for Flutter apps unless accessibility is enabled — the screenshot, not uiautomator, is the evidence. - Verify storage was created. Inspect the app's private dir:
adb -s <serial> shell run-as <packageId> ls -la app_flutter/thenfind app_flutter/<wikiRoot> -type f. Completion: expected files exist (e.g.index.sqlite,wiki.yaml). Quoting trap:run-as pkg sh -c '...'mangles nested quotes through adb — pass one simple command at a time, and inspectapp_flutter/(path_provider's documents dir) notfiles/.