AGENT SKILL

testing

Full QA procedure — interaction map, unit tests, Maestro flows, visual review

License 许可
Apache-2.0
所属仓库
bes-dev/etnamute
最近更新
2026-03-27
Stars
★ 12
Forks
1

01 前言 Front Matter

name
testing
description
Full QA procedure — interaction map, unit tests, Maestro flows, visual review

03 SKILL.md 正文

Complete testing procedure for an app. Follow EVERY step in order. Do NOT skip steps.

Step 1: Interaction map

Read .claude/skills/interaction-map/SKILL.md and build the full interaction map for the app.

Output: table of all interactive elements with effect types. Report any bugs found (broken promises).

Step 1.5: Scan for gesture interactions

Grep the codebase for gesture-based components that are invisible in the UI but crash if not set up correctly:

Swipeable, ReanimatedSwipeable, PanGestureHandler, LongPressGestureHandler,
FlingGestureHandler, PinchGestureHandler, Draggable, pull-to-refresh (RefreshControl)

For each one found:

  • Verify GestureHandlerRootView wraps the app root
  • Verify Reanimated babel plugin is configured (if using ReanimatedSwipeable)
  • Add to the test plan: this gesture MUST have a Maestro flow that physically executes it

Gestures are a blind spot — tsc, bundler, unit tests, and runtime log checks all pass while the app crashes on first swipe.

Step 2: Generate tests

Based on the interaction map + gesture scan:

Unit tests (__tests__/):

  • Every "state without visual" or "side effect" element → fireEvent.press → verify store/mock
  • Every "visual on current screen" element → fireEvent.press → verify state changed (backup for Maestro)

Maestro flows (.maestro/):

Before writing ANY flow:

  1. Fetch Maestro docs via mcpdoc — verify available commands
  2. Read .claude/skills/maestro/SKILL.md — flow template, tab coordinates, keyboard patterns

Then generate flows from the interaction map:

Smoke (tags: smoke): launch → navigate all tabs → no crash Functional (tags: functional): one flow per screen or feature group Persistence (tags: persistence): add data → killApp → relaunch → verify Errors (tags: errors): invalid input → error shown → fix → success Gestures (tags: functional): for each gesture found in Step 1.5 — swipe/long-press/drag → verify effect + verify no crash

RULES:

  • Copy the flow template from maestro skill — do NOT improvise structure
  • Every tapOn → extendedWaitUntil (never waitForAnimationToEnd)
  • Tab navigation → use coordinate table from maestro skill
  • Keyboard dismissal → tap a label (never hideKeyboard)
  • Cross-screen effects → navigate + takeScreenshot for Claude visual review

Step 3: Run tests

# Unit tests
npx jest --passWithNoTests

# Maestro (all flows via smoke.sh)
../../scripts/smoke.sh .

NEVER run Maestro manually. ALWAYS use smoke.sh.

If smoke.sh fails → fix the cause (flow, code, or script) → re-run. Max 3 attempts.

Step 4: Visual review

Read .claude/skills/visual-review/SKILL.md and review EVERY screenshot from Step 3.

Step 5: Report

## Test Report: <app-name>

### Interaction Map
| Element | Effect type | Test method | Result |
|---------|------------|-------------|--------|

### Unit Tests
- X passed, Y failed

### Maestro Flows
- X passed, Y failed

### Visual Verification
- Screenshots reviewed: X
- Issues found: <list>

### Verdict: PASS / NEEDS FIXES

04 同仓库更多 Skills