MCPcopy Create free account
hub / github.com/ipython/traitlets / test_logger_adapter

Function test_logger_adapter

tests/config/test_configurable.py:704–712  ·  view source on GitHub ↗
(caplog, capsys)

Source from the content-addressed store, hash-verified

702
703
704def test_logger_adapter(caplog, capsys):
705 logger = logging.getLogger("Application")
706 adapter = logging.LoggerAdapter(logger, {"key": "adapted"})
707
708 app = Application(log=adapter, log_level=logging.INFO)
709 app.log_format = "%(key)s %(message)s"
710 app.log.info("test message")
711
712 assert "adapted test message" in capsys.readouterr().err

Callers

nothing calls this directly

Calls 2

ApplicationClass · 0.90
infoMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…