module documentation
Undocumented
Class |
|
The details of a call to :meth:`_AgentSpy.request` |
Function | agent |
Record HTTP requests made with an agent |
Class | _ |
An agent that records HTTP requests |
Record HTTP requests made with an agent This is suitable for low-level testing of wrapper agents. It validates the parameters of each call to :meth:`IAgent.request` (synchronously raising :exc:`TypeError`) and captures them as a :class:`RequestRecord`, which can then be used to inspect the request or generate a response by firing the :attr:`~RequestRecord.deferred`. :returns: A two-tuple of: - An :class:`twisted.web.iweb.IAgent` - A list of calls made to the agent's :meth:`~twisted.web.iweb.IAgent.request()` method