Пример #1
0
def test_log_plugin_disabled():
  plugin = AuroraLogConfigurationPlugin()

  plugin.before_dispatch(["aurora", "version"])

  assert logging.getLogger().getEffectiveLevel() == logging.INFO
  assert logging.getLogger('requests_kerberos').getEffectiveLevel() == logging.CRITICAL
Пример #2
0
def test_log_plugin_enabled():
  plugin = AuroraLogConfigurationPlugin()

  plugin.before_dispatch(["aurora", "version", "--verbose"])

  assert logging.getLogger().getEffectiveLevel() == logging.DEBUG
  assert logging.getLogger('requests_kerberos').getEffectiveLevel() == logging.DEBUG