MCPcopy Create free account
hub / github.com/hynek/structlog / test_find_caller

Method test_find_caller

tests/test_stdlib.py:144–154  ·  view source on GitHub ↗

The caller is found.

(self, caplog)

Source from the content-addressed store, hash-verified

142 assert None is stack_info
143
144 def test_find_caller(self, caplog):
145 """
146 The caller is found.
147 """
148 logger = LoggerFactory()()
149
150 logger.error("Test")
151
152 assert caplog.text.startswith(
153 "ERROR tests.test_stdlib:test_stdlib.py"
154 )
155
156 def test_sets_correct_logger(self):
157 """

Callers

nothing calls this directly

Calls 2

LoggerFactoryClass · 0.90
errorMethod · 0.45

Tested by

no test coverage detected