mirror of
https://github.com/freqtrade/freqtrade.git
synced 2025-11-29 00:23:07 +00:00
Merge remote-tracking branch 'origin/develop' into develop
This commit is contained in:
@@ -50,6 +50,6 @@ def restore_verbosity_for_bias_tester() -> None:
|
||||
Restore verbosity after bias tester.
|
||||
"""
|
||||
logger.info("Restoring log verbosity.")
|
||||
log_level = logging.getLogger('freqtrade').getEffectiveLevel()
|
||||
log_level = logging.NOTSET
|
||||
for logger_name in __BIAS_TESTER_LOGGERS:
|
||||
logging.getLogger(logger_name).setLevel(log_level)
|
||||
|
||||
@@ -133,16 +133,17 @@ def test_set_loggers_journald_importerror(import_fails):
|
||||
|
||||
|
||||
def test_reduce_verbosity():
|
||||
setup_logging_pre()
|
||||
reduce_verbosity_for_bias_tester()
|
||||
|
||||
assert logging.getLogger('freqtrade.resolvers').level is logging.WARNING
|
||||
assert logging.getLogger('freqtrade.strategy.hyper').level is logging.WARNING
|
||||
assert logging.getLogger('freqtrade.resolvers').getEffectiveLevel() is logging.WARNING
|
||||
assert logging.getLogger('freqtrade.strategy.hyper').getEffectiveLevel() is logging.WARNING
|
||||
# base level wasn't changed
|
||||
assert logging.getLogger('freqtrade').level is logging.INFO
|
||||
assert logging.getLogger('freqtrade').getEffectiveLevel() is logging.INFO
|
||||
|
||||
restore_verbosity_for_bias_tester()
|
||||
|
||||
assert logging.getLogger('freqtrade.resolvers').level is logging.INFO
|
||||
assert logging.getLogger('freqtrade.strategy.hyper').level is logging.INFO
|
||||
assert logging.getLogger('freqtrade').level is logging.INFO
|
||||
assert logging.getLogger('freqtrade.resolvers').getEffectiveLevel() is logging.INFO
|
||||
assert logging.getLogger('freqtrade.strategy.hyper').getEffectiveLevel() is logging.INFO
|
||||
assert logging.getLogger('freqtrade').getEffectiveLevel() is logging.INFO
|
||||
# base level wasn't changed
|
||||
|
||||
Reference in New Issue
Block a user