mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Show logs in failed tests
Output from IPA's log manager is not captured by Nose's logcapture plugin. Forward IPA logs to a regular Python logger so that they are shown on failures. IPA log messages are also shown on standard error. Filter out Paramiko logs by default; these are too verbose. Part of the work for: https://fedorahosted.org/freeipa/ticket/3621
This commit is contained in:
@@ -88,6 +88,10 @@ class BeakerLibPlugin(Plugin):
|
||||
self.setup_log_handler(BeakerLibLogHandler(self.run_beakerlib_command))
|
||||
|
||||
def setup_log_handler(self, handler):
|
||||
# Remove the console handler (BeakerLib will print to stderr)
|
||||
if 'console' in log_mgr.handlers:
|
||||
log_mgr.remove_handler('console')
|
||||
# Configure our logger
|
||||
log_mgr.configure(
|
||||
{
|
||||
'default_level': 'DEBUG',
|
||||
|
||||
Reference in New Issue
Block a user