Skip to content

Reference

rn-tester

The tester agent verifies that an implemented feature works correctly on a live simulator or emulator. It navigates to the feature, exercises user flows, checks internal state, and generates persistent Maestro test files.

PropertyValue
ModelOpus
ColorCyan
Skillsrn-device-control, rn-testing, rn-debugging
ToolsBash, Read, Write, Edit, Glob, Grep, all MCP CDP/device tools
  • “test this feature on the simulator”
  • “verify the login flow works”
  • “does the cart badge update when I add items?”
  • Phase 5.5 of the rn-feature-dev pipeline
  • /test-feature command

Requires the intended rn_session, then uses passive cdp_status for the bound Metro/CDP target, cdp_component_tree for render health, and cdp_error_log for errors. Missing authority stops the run instead of selecting ambient state.

Reads git diff to discover changed files. Identifies screens, testIDs, store slices, API endpoints, navigation routes, bundle ID, and URI scheme.

Writes a test plan before executing: starting state, steps to exercise, expected outcomes at each step, and edge cases.

Checks cdp_navigation_state for auth-gated screens. If logged out, calls cdp_login_prologue, which resolves only the exact user-login action and requires a fresh passing RunRecord. A failed replay ends the journey without credential or ad-hoc replay fallbacks; it does not latch the session. The helper is not PR proof; formal login proof locks and runs the exact login e2e candidate.

For permission-gated flows, queries and sets the required permission state (grant/revoke/reset) before navigating. Handles platform differences between iOS and Android.

Uses cdp_nav_graph to build a multi-step navigation plan with reliability scores, prerequisites, and deep link alternatives.

Executes the navigation plan from Step 2.7 using programmatic navigation, deep links, or UI fallback. Records outcomes for each step to improve future reliability.

The core test loop. For each step:

  1. Act using the device tools (device_find, device_press) or Maestro for persistent test files
  2. Wait for UI to settle via device_snapshot or Maestro assertVisible
  3. Verify UI with screenshot + cdp_component_tree (filtered)
  4. Verify Data with cdp_store_state and cdp_network_log

Tests empty/initial state, error state, back navigation, and rapid interactions.

Writes a complete Maestro YAML flow file at flows/<feature-name>.yaml for CI.

Summarizes steps that passed (with evidence), steps that failed (with screenshot + state dump), and the generated Maestro test file path.

Tracks failures by category. After 3 failures of the same type, stops and reports the blocker.

CategoryAfter 3 failures
ScreenshotReport “simulator may be unresponsive”
Device interactionReport which element failed, ask user
CDP queryReport “CDP connection lost”
App launchReport error, suggest rebuild
Maestro flowReport flow error output
  • Never changes git state (no checkout, stash, reset, clean)
  • Never clears app data unless explicitly asked
  • Never uses clearState: true with Expo Dev Client builds
  • Uses a single device consistently throughout the test