mirror of https://github.com/python/cpython
Repair logging test spew caused by rev. 51206.
This commit is contained in:
parent
953c1897d2
commit
f3e304297e
|
@ -79,7 +79,7 @@ def fileConfig(fname, defaults=None):
|
|||
logging._acquireLock()
|
||||
try:
|
||||
logging._handlers.clear()
|
||||
logging._handlerList = []
|
||||
del logging._handlerList[:]
|
||||
# Handlers add themselves to logging._handlers
|
||||
handlers = _install_handlers(cp, formatters)
|
||||
_install_loggers(cp, handlers)
|
||||
|
|
|
@ -493,7 +493,7 @@ def test4():
|
|||
try:
|
||||
logging._handlers.clear()
|
||||
logging._handlers.update(saved_handlers)
|
||||
logging._handlerList = saved_handler_list
|
||||
logging._handlerList[:] = saved_handler_list
|
||||
loggerDict = logging.getLogger().manager.loggerDict
|
||||
loggerDict.clear()
|
||||
loggerDict.update(saved_loggers)
|
||||
|
@ -560,7 +560,7 @@ def test5():
|
|||
try:
|
||||
logging._handlers.clear()
|
||||
logging._handlers.update(saved_handlers)
|
||||
logging._handlerList = saved_handler_list
|
||||
logging._handlerList[:] = saved_handler_list
|
||||
loggerDict = logging.getLogger().manager.loggerDict
|
||||
loggerDict.clear()
|
||||
loggerDict.update(saved_loggers)
|
||||
|
|
Loading…
Reference in New Issue