class documentation
class IntegrationTestingMixin: (source)
Known subclasses: twisted.web.test.test_agent.AgentHTTPSTests
, twisted.web.test.test_agent.AgentTests
Transport-to-Agent integration tests for both HTTP and HTTPS.
Method | integration |
Agent will make a TCP connection, send an HTTP request, and return a Deferred that fires when the response has been received. |
Method | test_integration |
Agent works over IPv4. |
Method | test_integration |
Agent works over IPv4 when hostname is an IPv4 address. |
Method | test_integration |
Agent works over IPv6. |
Method | test_integration |
Agent works over IPv6 when hostname is an IPv6 address. |
def integrationTest(self, hostName, expectedAddress, addressType, serverWrapper=(lambda server: server), createAgent=client.Agent, scheme=b'http'):
(source)
¶
overridden in
twisted.web.test.test_agent.AgentHTTPSTests
Agent
will make a TCP connection, send an HTTP request, and return a Deferred
that fires when the response has been received.
Parameters | |
hostbytes | The hostname to interpolate into the URL to be requested. |
expectedbytes | The expected address string. |
addresstype | The class to construct an address out of. |
servertwisted.internet.interfaces.IProtocolFactory ) -> twisted.internet.interfaces.IProtocolFactory | A callable that takes a protocol factory and returns a protocol factory; used to wrap the server / responder side in a TLS server. |
createIAgent | A callable that takes a reactor and produces an IAgent ; used to construct an agent with an appropriate trust root for TLS. |
scheme:bytes | The scheme to test, http or https |