summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--snaps/openstack/tests/create_instance_tests.py14
1 files changed, 10 insertions, 4 deletions
diff --git a/snaps/openstack/tests/create_instance_tests.py b/snaps/openstack/tests/create_instance_tests.py
index 2cb1cdc..765def7 100644
--- a/snaps/openstack/tests/create_instance_tests.py
+++ b/snaps/openstack/tests/create_instance_tests.py
@@ -312,11 +312,17 @@ class SimpleHealthCheck(OSIntegrationTestCase):
if os.path.isfile(self.keypair_priv_filepath):
os.remove(self.keypair_priv_filepath)
+ if self.network_creator:
+ try:
+ self.network_creator.clean()
+ except Exception as e:
+ logger.error('Unexpected exception cleaning network with message - ' + e.message)
+
if self.flavor_creator:
try:
self.flavor_creator.clean()
except Exception as e:
- logger.error('Unexpected exception cleaning network with message - ' + e.message)
+ logger.error('Unexpected exception cleaning flavor with message - ' + e.message)
if self.image_creators:
try:
@@ -396,7 +402,7 @@ class CreateInstanceSimpleTests(OSIntegrationTestCase):
self.image_creators = list()
self.flavor_creator = None
- self.net_creator = None
+ self.network_creator = None
self.inst_creator = None
try:
@@ -460,9 +466,9 @@ class CreateInstanceSimpleTests(OSIntegrationTestCase):
except Exception as e:
logger.error('Unexpected exception cleaning flavor with message - ' + e.message)
- if self.net_creator:
+ if self.network_creator:
try:
- self.net_creator.clean()
+ self.network_creator.clean()
except Exception as e:
logger.error('Unexpected exception cleaning network with message - ' + e.message)