(rid, req)
| 604 | assert init["subtype"] == "init" |
| 605 | |
| 606 | async def _reply_for(rid, req): |
| 607 | await handle.send_to_agent({"type": "control_request", "request_id": rid, "request": req}) |
| 608 | for _ in range(12): |
| 609 | msg = await asyncio.wait_for(gen.__anext__(), timeout=5) |
| 610 | if msg.get("type") == "control_response" and msg["response"].get("request_id") == rid: |
| 611 | return msg["response"]["response"] |
| 612 | raise AssertionError(f"no reply for {rid}") |
| 613 | |
| 614 | ok = await _reply_for("s1", {"subtype": "set_output_style", "style": "concise"}) |
| 615 | assert ok["ok"] is True and ok["style"] == "concise" |
no test coverage detected