Browse Source

Use tests.base as base class for tests

The class tets.base is now used as base class for tests. The base
class itself inherits from Neurons base class.

The only exception is the mechanism driver test, as this one directly
inherits from the neutron mechanism drier test.

Change-Id: I71efb848df47fbd2ff8aa550fc5b8c2e47c3dbfc
Andreas Scheuring 2 years ago
parent
commit
6a41e154d4

+ 2
- 2
networking_dpm/tests/base.py View File

@@ -15,9 +15,9 @@
15 15
 # License for the specific language governing permissions and limitations
16 16
 # under the License.
17 17
 
18
-from oslotest import base
18
+from neutron.tests import base
19 19
 
20 20
 
21
-class TestCase(base.BaseTestCase):
21
+class BaseTestCase(base.BaseTestCase):
22 22
 
23 23
     """Test case base class for all unit tests."""

+ 1
- 2
networking_dpm/tests/unit/conf/test_config.py View File

@@ -17,9 +17,8 @@
17 17
 from os_dpm.config import config as os_dpm_conf
18 18
 from oslo_config import cfg
19 19
 
20
-from neutron.tests import base
21
-
22 20
 from networking_dpm.conf import config
21
+from networking_dpm.tests import base
23 22
 
24 23
 
25 24
 class TestConfig(base.BaseTestCase):

+ 1
- 1
networking_dpm/tests/unit/ml2/test_dpm_neutron_agent.py View File

@@ -24,10 +24,10 @@ from zhmcclient import HTTPError
24 24
 from networking_dpm.ml2 import dpm_neutron_agent as dpm_agt
25 25
 from networking_dpm.ml2.dpm_neutron_agent import (PhysicalNetworkMapping as
26 26
                                                   dpm_map)
27
+from networking_dpm.tests import base
27 28
 from networking_dpm.tests.unit import fake_zhmcclient
28 29
 
29 30
 from neutron.common import topics
30
-from neutron.tests import base
31 31
 
32 32
 
33 33
 class TestPhysnetMapping(base.BaseTestCase):

+ 1
- 2
networking_dpm/tests/unit/test_fake_zhmcclient.py View File

@@ -12,8 +12,7 @@
12 12
 # See the License for the specific language governing permissions and
13 13
 # limitations under the License.
14 14
 
15
-from neutron.tests import base
16
-
15
+from networking_dpm.tests import base
17 16
 from networking_dpm.tests.unit import fake_zhmcclient
18 17
 
19 18
 

Loading…
Cancel
Save