Automate a smoke test of your Android app
Quando usar: You want 'app opens, login, main screen loads' as an auto-run before every release.
Pré-requisitos
- ADB installed and device connected — Android Studio ships ADB;
adb devicesshould show your device - Device has USB debugging or wireless debugging on — Settings > Developer Options > USB Debugging
Fluxo
-
Capture current stateGet the UI state — what screen am I on and what elements are visible?✓ Copiado→ UI tree with labeled elements
-
Execute the flowTap the 'Sign In' button, type '[email protected]' in the email field, 'P@ss' in password, submit.✓ Copiado→ App transitions to home
-
Assert successVerify the home screen's 'Welcome' banner is visible. If not, fail.✓ Copiado→ Pass/fail verdict
Resultado: A scriptable smoke test you can run on every build.
Armadilhas
- Coordinates change between device sizes — Prefer State-Tool queries that find elements by label/id, then click the returned coordinates
- Flow breaks on A/B tests — Pin build config or disable experiments for QA builds