MCPcopy
hub / github.com/mitmproxy/mitmproxy / test_basic

Method test_basic

test/mitmproxy/test_connection.py:11–23  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

9
10class TestConnection:
11 def test_basic(self):
12 c = Client(
13 peername=("127.0.0.1", 52314),
14 sockname=("127.0.0.1", 8080),
15 timestamp_start=1607780791,
16 state=ConnectionState.OPEN,
17 )
18 assert not c.tls_established
19 c.timestamp_tls_setup = 1607780792
20 assert c.tls_established
21 assert c.connected
22 c.state = ConnectionState.CAN_WRITE
23 assert not c.connected
24
25 def test_eq(self):
26 c = tclient_conn()

Callers

nothing calls this directly

Calls 1

ClientClass · 0.90

Tested by

no test coverage detected