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

Function test_error_message

test/mitmproxy/addons/test_errorcheck.py:29–35  ·  view source on GitHub ↗
(capsys)

Source from the content-addressed store, hash-verified

27
28
29async def test_error_message(capsys):
30 e = ErrorCheck()
31 logging.error("wat")
32 logging.error("wat")
33 with pytest.raises(SystemExit):
34 await e.shutdown_if_errored()
35 assert "Errors logged during startup, exiting..." in capsys.readouterr().err
36
37
38async def test_repeat_error_on_stderr(capsys):

Callers

nothing calls this directly

Calls 3

shutdown_if_erroredMethod · 0.95
ErrorCheckClass · 0.90
errorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…