MCPcopy
hub / github.com/mitmproxy/mitmproxy / TAddon

Class TAddon

test/mitmproxy/test_addonmanager.py:17–36  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15
16
17class TAddon:
18 def __init__(self, name, addons=None):
19 self.name = name
20 self.response = True
21 self.running_called = False
22 if addons:
23 self.addons = addons
24
25 @command.command("test.command")
26 def testcommand(self) -> str:
27 return "here"
28
29 def __repr__(self):
30 return "Addon(%s)" % self.name
31
32 def done(self):
33 pass
34
35 def running(self):
36 self.running_called = True
37
38
39class AsyncTAddon(TAddon):

Callers 6

test_commandFunction · 0.70
test_haltFunction · 0.70
test_lifecycleFunction · 0.70
test_mixed_async_syncFunction · 0.70
test_simpleFunction · 0.70
test_nestingFunction · 0.70

Calls

no outgoing calls

Tested by 6

test_commandFunction · 0.56
test_haltFunction · 0.56
test_lifecycleFunction · 0.56
test_mixed_async_syncFunction · 0.56
test_simpleFunction · 0.56
test_nestingFunction · 0.56

Used in the wild real call sites across dependent graphs

searching dependent graphs…