New submission from Berker Peksag: It would be useful if we could change the logging format of assertLogs when we use it:
with self.assertLogs('foo', level='INFO', format='%(message)s') as cm: logging.getLogger('foo').info('first message') self.assertEqual(cm.output, ['first message']) Or maybe with a class attribute like maxDiff: logFormat = '%(message)s' ---------- components: Library (Lib) messages: 243182 nosy: berker.peksag, ezio.melotti, michael.foord, rbcollins priority: normal severity: normal stage: needs patch status: open title: Make LOGGING_FORMAT of assertLogs configurable type: enhancement versions: Python 3.5 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue24193> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com