MCPcopy Create free account
hub / github.com/apache/impala / configure_logging

Function configure_logging

tests/conftest.py:78–91  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

76
77
78def configure_logging():
79 # Use a "--" since most of our tests output SQL commands, and it's nice to
80 # be able to copy-paste directly from the test output back into a shell to
81 # try to reproduce a failure.
82 #
83 # This call only takes effect if it is the first call to logging.basicConfig().
84 # For example, if some other library calls logging.basicConfig() at the global
85 # level, then importing that library can render this call ineffective.
86 logging.basicConfig(level=logging.INFO, format=LOG_FORMAT)
87
88 # Verify that the logging level is set to the correct value.
89 rootLoggerLevel = logging.getLogger().getEffectiveLevel()
90 print("rootLoggerLevel = {0}".format(logging.getLevelName(rootLoggerLevel)))
91 assert (rootLoggerLevel == logging.INFO)
92
93
94def pytest_addoption(parser):

Callers 2

run-tests.pyFile · 0.90
pytest_configureFunction · 0.70

Calls 1

formatMethod · 0.45

Tested by

no test coverage detected