diff --git a/tests/__init__.py b/tests/__init__.py index 099ef57e..568c8991 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -4982,12 +4982,9 @@ def get_random_datetime_range(start_date=EWSDate(1990, 1, 1), end_date=EWSDate(2 if '-q' in sys.argv: sys.argv.remove('-q') - loglevel = logging.WARNING - logging.basicConfig(level=loglevel) + logging.basicConfig(level=logging.WARNING) else: from exchangelib.util import PrettyXmlHandler - loglevel = logging.DEBUG - logging.basicConfig(level=loglevel, handlers=[PrettyXmlHandler()]) + logging.basicConfig(level=logging.DEBUG, handlers=[PrettyXmlHandler()]) - logging.getLogger('exchangelib').setLevel(loglevel) unittest.main()