diff options
| author | Mark McLoughlin <markmc@redhat.com> | 2012-12-12 08:12:11 +0000 |
|---|---|---|
| committer | Mark McLoughlin <markmc@redhat.com> | 2012-12-16 22:24:07 +0000 |
| commit | 19558abd2b174f16d74809cd159451effc6d2ac2 (patch) | |
| tree | 8b1f2cef454169bb573ac609323001406b8e3a0e /nova/tests | |
| parent | 06f0e45712288525d0ae31d133efe30156a1ed71 (diff) | |
Move network_driver into new nova.network.driver
Add a new load_network_driver() function which constrains the use of the
network_driver option and move the option into nova.network.driver.
blueprint: scope-config-opts
Change-Id: I0a839765890093dc871b48435cfd113e0f8e46c4
Diffstat (limited to 'nova/tests')
| -rw-r--r-- | nova/tests/network/test_linux_net.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/nova/tests/network/test_linux_net.py b/nova/tests/network/test_linux_net.py index 68aaa6251..243b0ee56 100644 --- a/nova/tests/network/test_linux_net.py +++ b/nova/tests/network/test_linux_net.py @@ -21,16 +21,14 @@ import mox from nova import context from nova import db +from nova.network import driver from nova.network import linux_net -from nova.openstack.common import cfg from nova.openstack.common import fileutils from nova.openstack.common import importutils from nova.openstack.common import log as logging from nova import test from nova import utils -CONF = cfg.CONF -CONF.import_opt('network_driver', 'nova.config') LOG = logging.getLogger(__name__) HOST = "testhost" @@ -214,8 +212,7 @@ class LinuxNetworkTestCase(test.TestCase): def setUp(self): super(LinuxNetworkTestCase, self).setUp() - network_driver = CONF.network_driver - self.driver = importutils.import_module(network_driver) + self.driver = driver.load_network_driver() self.driver.db = db self.context = context.RequestContext('testuser', 'testproject', is_admin=True) |
