MCPcopy
hub / github.com/Delgan/loguru / test_remove_interception

Function test_remove_interception

tests/test_interception.py:65–75  ·  view source on GitHub ↗
(writer)

Source from the content-addressed store, hash-verified

63
64
65def test_remove_interception(writer):
66 h = InterceptHandler()
67
68 with make_logging_logger("foobar", h) as logging_logger:
69 logger.add(writer, format="{message}")
70 logging_logger.debug("1")
71 logging_logger.removeHandler(h)
72 logging_logger.debug("2")
73
74 result = writer.read()
75 assert result == "1\n"
76
77
78def test_intercept_too_low(writer):

Callers

nothing calls this directly

Calls 5

InterceptHandlerClass · 0.85
make_logging_loggerFunction · 0.85
addMethod · 0.80
debugMethod · 0.80
readMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…