Fix bug for running unittest with unittest module

When we run unittest with a way like:
python -m unittest2 <test_file>
then NoSuchOptError exception will raised

Change-Id: Ib0f9276c1b86ff7f2d1e401ddfae2bf4e920fa78
This commit is contained in:
wangwei1 2019-11-14 15:21:49 +08:00
parent 28fabef6ec
commit d56877b3fe
1 changed files with 2 additions and 0 deletions

View File

@ -27,6 +27,8 @@ from karbor.tests import base
from karbor.tests.unit.protection import fakes
CONF = cfg.CONF
CONF.import_opt('trigger_poll_interval', 'karbor.services.operationengine'
'.engine.triggers.timetrigger')
class ProtectionServiceTest(base.TestCase):