wait_for_activity
Wait until a specified Android activity becomes the foreground (resumed) activity, with configurable timeout and polling interval. Use it to synchronize test steps after launching or navigating to a screen.
Instructions
Wait until a specific activity becomes the foreground (resumed) activity
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| activity | Yes | Activity name or partial match (e.g., '.MainActivity' or 'com.example/.MainActivity') | |
| device_id | No | Target device ID. If omitted, uses the default device. | |
| timeout_ms | No | Maximum time to wait in milliseconds (default: 10000) | |
| poll_interval_ms | No | Polling interval in milliseconds (default: 500) |