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

Method test_get_effective_level

tests/test_stdlib.py:318–328  ·  view source on GitHub ↗

get_effective_level is a snake_case alias that delegates to the wrapped logger's getEffectiveLevel, for compatibility with FilteringBoundLogger.

(self)

Source from the content-addressed store, hash-verified

316 assert bl.is_enabled_for(DEBUG) is False
317
318 def test_get_effective_level(self):
319 """
320 get_effective_level is a snake_case alias that delegates to the wrapped
321 logger's getEffectiveLevel, for compatibility with
322 FilteringBoundLogger.
323 """
324 stdlib_logger = logging.getLogger("test_get_effective_level")
325 stdlib_logger.setLevel(WARN)
326 bl = BoundLogger(stdlib_logger, [], {})
327
328 assert WARN == bl.get_effective_level()
329
330 def test_exception_exc_info(self):
331 """

Callers

nothing calls this directly

Calls 3

get_effective_levelMethod · 0.95
BoundLoggerClass · 0.90
setLevelMethod · 0.80

Tested by

no test coverage detected