android-ui-journey-testing
Skill này làm gì
Công cụ này kiểm thử cách một ứng dụng Android hoạt động. Nó làm theo một chuỗi bước được định nghĩa trong file đặc biệt (XML) để kiểm tra mọi thứ có hoạt động như mong đợi không, mô phỏng người dùng tương tác với ứng dụng.
Khi nào nên dùng
- ✓Khi muốn kiểm tra ứng dụng Android có hoạt động đúng không.
- ✓Khi cần tự động hóa các tác vụ gồm nhiều lần nhấp và kiểm tra.
- ✓Khi muốn có báo cáo chi tiết dạng file (JSON) về các bài kiểm thử.
Liên kết skill
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/android-ui-journey-testing/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Kiểm thử luồng đăng nhập và xác minh tên người dùng xuất hiện trên màn hình chính.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Công cụ đọc file hướng dẫn (XML) quy định cần làm gì, như nhấp nút hoặc kiểm tra xem có thứ gì trên màn hình không. Nó thực hiện từng bước, ghi lại thành công hay thất bại và tạo báo cáo cuối cùng.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Android UI Journey Testing
Overview
This skill outlines the standard workflow for running XML-specified User Journey tests on Android applications. A "journey" is a sequenced set of user actions and state assertions designed to verify end-to-end functionality. The journey XML acts as the source of truth for the app's behavior. The executor proceeds sequentially, performing UI interactions, checking state assertions, and writing a standardized JSON outcome report.
When to Use
- Use when evaluating an Android application's UI behavior against an XML test specification.
- Use when automating multi-step user flows (e.g., login, checkout, navigation) and verifying expectations.
- Use when running verification tests and generating standardized JSON test reports.
- Use when debugging application flows on physical devices or emulators using ADB commands.
How It Works
graph TD
A[Parse Journey XML] --> B[Execute Action / Interaction]
B --> C{Success?}
C -- Yes --> D[Verify State Expectation / Assertion]
C -- No/Crash --> G[Mark FAILED & Exit]
D -- Passed --> E{More Steps?}
D -- Failed --> G
E -- Yes --> B
E -- No --> F[Output JSON Summary]
Step 1: Parse the Journey Specification
Read and parse the XML test suite structure. The root node <journey> defines the test case name, and the <actions> block contains the sequence of test steps.
<journey name="Search and Cart Flow">
<description>Verify that searching for an item and adding it to the cart succeeds.</description>
<actions>
<action>Search for soda</action>
<action>Tap the first search result</action>
<action>Verify that the product detail screen is shown</action>
</actions>
</journey>
Step 2: Sequential Step Evaluation
Process each <action> element in the exact order specified. Test steps are classified into two groups:
A. Interactive Actions (Taps, Swipes, Text Input)
Perform the physical UI interaction using ADB.
- Tapping: Tap the center of the target element's bounds:
adb shell input tap <x> <y> - Swiping/Scrolling: Swipe from coordinate to coordinate with a duration:
adb shell input swipe <x1> <y1> <x2> <y2> <duration_ms> - Text Typing: Type text into the active input field:
adb shell input text "<string>"
If the element is missing or the action cannot be performed, the action and the journey fail.
B. State Assertions (Expectation Verification)
Steps beginning with "verify", "check", or "ensure" represent state assertions.
- Inspect the current screen (using screenshots or
uiautomator dump) without interacting or scrolling. - Confirm all sub-assertions are met. For example, "Verify that the app is on the Home screen and the logo is visible" fails if the home screen is not displayed or the logo is missing.
Step 3: Handle Failures and Crashes
If the application crashes, exits, freezes, or fails an assertion:
- Immediately stop journey execution.
- Mark the failed step as
FAILED. - Mark any subsequent steps as
SKIPPED. - Document the exact reason for failure.
Step 4: Generate JSON Report
Format the execution results into a standardized JSON schema and write it to the output log.
Examples
Example 1: Full Journey XML Specification
<journey name="Login and Profile Edit">
<description>Logs into the app, navigates to settings, and changes user profile information.</description>
<actions>
<action>Verify that the username input field is visible</action>
<action>Tap the username input field</action>
<action>Type "testuser" into the input</action>
<action>Tap the password input field</action>
<action>Type a redacted test password into the input</action>
<action>Tap the "Login" button</action>
<action>Verify that the Home dashboard is visible and user profile photo is shown</action>
</actions>
</journey>
Example 2: Standard JSON Outcome Report
{
"journey": "Login and Profile Edit",
"results": [
{
"action": "Verify that the username input field is visible",
"status": "PASSED",
"commands": [],
"comment": "Username input detected at bounds [100,200][980,300] via UI dump."
},
{
"action": "Tap the username input field",
"status": "PASSED",
"commands": [
"adb shell input tap 540 250"
],
…
Câu hỏi thường gặp
“Journey” là gì?
Đó là chuỗi hành động và kiểm tra mô phỏng việc sử dụng ứng dụng, như đăng nhập, thêm sản phẩm vào giỏ hàng, v.v.
File XML là gì?
Đó là file văn bản chứa các bước hướng dẫn cho bài kiểm thử. Nó quy định ứng dụng cần làm gì và cần kiểm tra điều gì.
Điều gì xảy ra nếu một bài kiểm thử thất bại?
Công cụ dừng thực thi tại bước đó, đánh dấu bước là thất bại và ghi lý do. Các bước sau sẽ được đánh dấu là bỏ qua.
Chi tiết
Mô tả gốc của tác giả
XML-specified Android UI journey testing, interactive step execution, assertion verification, and JSON outcome reporting.
Độ phổ biến
- Sao GitHub
- 48k
- Vị trí xếp hạng
- #3743
- Giấy phép
- MIT
- Cập nhật
- 15/10/2026
Bình luận
- …
Thêm skill từ kho mã này
00-andruia-consultant
48kGiúp agent của bạn bắt đầu hoặc cải thiện các dự án AI. Phân tích mã, gợi ý công cụ và lập kế hoạch hành động bằng tiếng Tây Ban Nha.
007
48kCho phép agent của bạn thực hiện kiểm toán bảo mật và mô hình hóa mối đe dọa. Hữu ích để bảo vệ dự án khỏi các cuộc tấn công và lỗ hổng.
10-andruia-skill-smith
48kGiúp agent của bạn tạo hoặc cải thiện các công cụ AI. Xác định cách công cụ hoạt động, viết tài liệu và kiểm tra cấu trúc.
20-andruia-niche-intelligence
48kGiúp agent của bạn tạo bản tóm tắt về một ngành cụ thể. Hữu ích để hiểu bối cảnh, quy tắc, cách người dùng tương tác và rủi ro của dự án.
Skill tương tự
test-driven-development
311kDạy agent của bạn viết kiểm thử thất bại trước, xem nó thất bại, rồi viết đoạn mã ngắn nhất để vượt qua trước khi làm bất kỳ tính năng hay bản sửa nào.
verification-before-completion
311kDạy agent của bạn chạy kiểm tra thực tế và đọc kết quả đầu ra trước khi khẳng định một việc, bản sửa hoặc bản build đã hoàn thành hay vượt qua.
migrate-to-shoehorn
310kThay các ép kiểu rủi ro trong tệp kiểm thử bằng thư viện shoehorn, để các bài kiểm thử dùng dữ liệu một phần vẫn qua được kiểm tra kiểu.