MCPcopy Index your code
hub / github.com/mitmproxy/mitmproxy / test_add_flows

Function test_add_flows

test/mitmproxy/addons/test_serverplayback.py:61–79  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

59
60
61def test_add_flows():
62 sp = serverplayback.ServerPlayback()
63 with taddons.context(sp) as tctx:
64 tctx.configure(sp)
65 f1 = tflow.tflow(resp=True)
66 f2 = tflow.tflow(resp=True)
67
68 sp.load_flows([f1])
69 sp.add_flows([f2])
70
71 assert sp.next_flow(f1)
72 assert sp.flowmap
73 assert sp.next_flow(f2)
74 assert not sp.flowmap
75
76 sp.add_flows([f1])
77 assert sp.flowmap
78 assert sp.next_flow(f1)
79 assert not sp.flowmap
80
81
82def test_ignore_host():

Callers

nothing calls this directly

Calls 5

load_flowsMethod · 0.95
add_flowsMethod · 0.95
next_flowMethod · 0.95
contextMethod · 0.80
configureMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…