Mock network responses
Trq can snapshot the app's API responses while you record and serve them back on replay — so runs are fast, repeatable, and offline-capable, and you can exercise error paths on demand. It reuses the same mock model as the web, and the snapshot travels inside the .trq bundle, so a mobile test carries its mock like a web one.
Turn it on
Open the mobile settings drawer (the ⚙ gear) → Network:
- Capture — record matching responses while you run.
- Serve on replay — on the next replay, serve the recorded responses instead of hitting the network.
A served request is badged as mocked in the Network tab. Matching is ordinal within a method + url — the first recorded response for a given call is served first, and so on.
Plain HTTP is captured and served in full. Encrypted HTTPS bodies are only available when HTTPS inspection is enabled; otherwise the mock covers HTTP responses. Responses an app cryptographically binds to each request (a fresh per-request nonce/signature it re-validates) can't be replayed by any mock — that's a property of the app, not Trq.