Allow to change test log dir with environmental variable
This commit is contained in:
parent
c0639fef75
commit
7ecf09a496
1 changed files with 2 additions and 0 deletions
|
@ -74,6 +74,8 @@ config.verbose = True # Use test data for unittests
|
|||
config.tor = "disable" # Don't start Tor client
|
||||
config.trackers = []
|
||||
config.data_dir = TEST_DATA_PATH # Use test data for unittests
|
||||
if "ZERONET_LOG_DIR" in os.environ:
|
||||
config.log_dir = os.environ["ZERONET_LOG_DIR"]
|
||||
config.initLogging(console_logging=False)
|
||||
|
||||
# Set custom formatter with realative time format (via: https://stackoverflow.com/questions/31521859/python-logging-module-time-since-last-log)
|
||||
|
|
Loading…
Reference in a new issue