From: Ross Brattain Date: Tue, 6 Jun 2017 06:59:25 +0000 (-0700) Subject: fix No handler warning by calling _init_logging X-Git-Tag: opnfv-5.0.RC1~460 X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=commitdiff_plain;h=6746ada2e8c837da948c3260ceb8829ea1fc27de;p=yardstick.git fix No handler warning by calling _init_logging No handlers could be found for logger It looks like we need to call _init_logging to properly setup the logging during unittests. This should fix the influxdb unittest warning. JIRA: YARDSTICK-506 Change-Id: I57f6e4088005a691d6587fc68b85455ff257a66c Signed-off-by: Ross Brattain --- diff --git a/tests/unit/dispatcher/test_influxdb.py b/tests/unit/dispatcher/test_influxdb.py index 0c7b58135..dca3c4189 100644 --- a/tests/unit/dispatcher/test_influxdb.py +++ b/tests/unit/dispatcher/test_influxdb.py @@ -14,11 +14,15 @@ from __future__ import absolute_import import unittest + try: from unittest import mock except ImportError: import mock +from yardstick import _init_logging +_init_logging() + from yardstick.dispatcher.influxdb import InfluxdbDispatcher