Skip to content
android_ui_verification logo

Android UI Verification Skill

android_ui_verification

Automated end-to-end UI testing and verification on an Android Emulator using ADB.

SKILL.md

Full skill instructions

Android UI Verification Skill

This skill provides a systematic approach to testing React Native applications on an Android emulator using ADB commands. It allows for autonomous interaction, state verification, and visual regression checking.

When to Use

  • Verifying UI changes in React Native or Native Android apps.
  • Autonomous debugging of layout issues or interaction bugs.
  • Ensuring feature functionality when manual testing is too slow.
  • Capturing automated screenshots for PR documentation.

🛠 Prerequisites

  • Android Emulator running.
  • adb installed and in PATH.
  • Application in debug mode for logcat access.

🚀 Workflow

1. Device Calibration

Before interacting, always verify the screen resolution to ensure tap coordinates are accurate.

adb shell wm size

Note: Layouts are often scaled. Use the physical size returned as the base for coordinate calculations.

2. UI Inspection (State Discovery)

Use the uiautomator dump to find the exact bounds of UI elements (buttons, inputs).

adb shell uiautomator dump /​sdcard/​view.xml && adb pull /​sdcard/​view.xml ./​artifacts/​view.xml

Search the view.xml for text, content-desc, or resource-id. The bounds attribute [x1,y1][x2,y2] defines the clickable area.

3. Interaction Commands

  • Tap: adb shell input tap <x> <y> (Use the center of the element bounds).
  • Swipe: adb shell input swipe <x1> <y1> <x2> <y2> <duration_ms> (Used for scrolling).
  • Text Input: adb shell input text "<message>" (Note: Limited support for special characters).
  • Key Events: adb shell input keyevent <code_id> (e.g., 66 for Enter).

4. Verification & Reporting

Visual Verification

Capture a screenshot after interaction to confirm UI changes.

adb shell screencap -p /​sdcard/​screen.png && adb pull /​sdcard/​screen.png ./​artifacts/​test_result.png
Analytical Verification

Monitor the JS console logs in real-time to detect errors or log successes.

adb logcat -d | grep "ReactNativeJS" | tail -n 20
Cleanup

Always store generated files in the artifacts/ folder to satisfy project organization rules.

💡 Best Practices

  • Wait for Animations: Always add a short sleep (e.g., 1-2s) between interaction and verification.
  • Center Taps: Calculate the arithmetic mean of [x1,y1][x2,y2] for the most reliable tap target.
  • Log Markers: Use distinct log messages in the code (e.g., ✅ Action Successful) to make grep verification easy.
  • Fail Fast: If a uiautomator dump fails or doesn't find the expected text, stop and troubleshoot rather than blind-tapping.

Limitations

  • Use this skill only when the task clearly matches the scope described above.
  • Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
  • Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.

More Mobile Development skills

vercel-react-native-skills logo
Mobile Development

vercel-react-native-skills

React Native and Expo best practices for performant mobile apps across list rendering, animations, navigation, and native modules.

31.9K 231.8K
View
firebase-data-connect logo
Mobile Development

firebase-data-connect

PostgreSQL-backed GraphQL backend with auto-generated type-safe SDKs for web, mobile, and Flutter.

462 158.3K
View
xcode-project-setup logo
Mobile Development

xcode-project-setup

Safely modifies Xcode projects (.pbxproj) to add Swift Packages and link files. Use this skill whenever an iOS project needs dependencies installed (e.g. Firebase, Alamofire).

462 120.2K
View
expo-dev-client logo
Mobile Development

expo-dev-client

Build custom Expo development clients for testing native code on physical devices via EAS Build or locally.

2.7K 64.8K
View
expo-module logo
Mobile Development

expo-module

Complete reference for building native modules and views with the Expo Modules API across Swift, Kotlin, and TypeScript.

2.7K 40.3K
View
swiftui-expert-skill logo
Mobile Development

swiftui-expert-skill

Expert SwiftUI code review, refactoring, and implementation guidance with iOS 26+ and macOS support.

3.7K 33.8K
View
swiftui-pro logo
Mobile Development

swiftui-pro

Comprehensive SwiftUI code review against modern APIs, accessibility, and performance standards.

5K 31.2K
View
react-native-best-practices logo
Mobile Development

react-native-best-practices

Provides React Native performance optimization guidelines for FPS, TTI, bundle size, memory leaks, re-renders, and animations. Applies to tasks involving Hermes optimization, JS thread blocking, bridge overhead, FlashList, native modules, or debugging jank and frame drops.

1.7K 27.9K
View
Expo App Design logo
Mobile Development

Expo App Design

Build native-feeling Expo screens — Apple HIG styling, semantic colors, and native UI patterns.

2.7K 25.2K
View
mobile-android-design logo
Mobile Development

mobile-android-design

Material Design 3 and Jetpack Compose patterns for building modern, adaptive Android applications.

40.2K 23.7K
View

Coding & apps AI tools

Opus Clip logo
Coding & apps

Opus Clip

Opus.ai: Revolutionize Your Web Experience

Free
View
Imagica logo
Coding & apps

Imagica

Build a no-code AI app in minutes.

Freemium
View
E
Coding & apps

Emergent.sh

An IDE for code migration from legacy to modern frameworks through coding agents.

Freemium
View
Wonder Dynamics logo
Coding & apps

Wonder Dynamics

Automate CGI animation in live-action scenes

Paid
View
M
Coding & apps

Mixo

Launch a website in seconds with AI.

Paid
View
AI Code Convert logo
Coding & apps

AI Code Convert

Streamline Your Coding Experience with AI Code Helper

Free
View