/usr/lib/python2.7/dist-packages/logging_tree/tests/case.py is in python-logging-tree 1.4-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 | """Common test class for `logging` tests."""
import logging.handlers
import unittest
class LoggingTestCase(unittest.TestCase):
"""Test case that knows the secret: how to reset the logging module."""
def tearDown(self):
super(LoggingTestCase, self).tearDown()
logging.root = logging.RootLogger(logging.WARNING)
logging.Logger.root = logging.root
logging.Logger.manager = logging.Manager(logging.Logger.root)
|