summaryrefslogtreecommitdiffstats
path: root/snaps/openstack/tests/openstack_tests.py
diff options
context:
space:
mode:
authorspisarski <s.pisarski@cablelabs.com>2018-01-29 14:05:18 -0700
committerspisarski <s.pisarski@cablelabs.com>2018-01-29 14:05:18 -0700
commit16f26ac0ba25aa7a4855a4a1b0700fecb5a272da (patch)
treed5e54e8a71b0ca1cd46d3c13ee3a1ca11d9effee /snaps/openstack/tests/openstack_tests.py
parentb4ddabd5af178f0e8bc33fb694facb20fea354ea (diff)
Changed the way floating IPs are getting assigned to VMs as the previous
means was not compatible with python-novaclient==10.0.0 JIRA: SNAPS-258 Change-Id: I56f7a8341c81e0ae5596f67d4d15ef6c26e0e680 Signed-off-by: spisarski <s.pisarski@cablelabs.com>
Diffstat (limited to 'snaps/openstack/tests/openstack_tests.py')
-rw-r--r--snaps/openstack/tests/openstack_tests.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/snaps/openstack/tests/openstack_tests.py b/snaps/openstack/tests/openstack_tests.py
index a3dec11..3c32eb7 100644
--- a/snaps/openstack/tests/openstack_tests.py
+++ b/snaps/openstack/tests/openstack_tests.py
@@ -15,7 +15,6 @@
import logging
import re
-import pkg_resources
from snaps import file_utils
from snaps.config.image import ImageConfig
from snaps.config.network import NetworkConfig, SubnetConfig
@@ -139,6 +138,10 @@ def get_credentials(os_env_file=None, proxy_settings_str=None,
if overrides and isinstance(overrides, dict):
creds_dict.update(overrides)
+ for key, value in creds_dict.items():
+ if value is not None and isinstance(value, str):
+ creds_dict[key] = value.replace('"', '').replace('\'', '')
+
os_creds = OSCreds(**creds_dict)
logger.info('OS Credentials = %s', os_creds.__str__)
return os_creds
@@ -336,11 +339,10 @@ class OSNetworkConfig:
router_name=None, external_gateway=None,
netconf_override=None):
"""
- :param netconf_override: dict() containing the reconfigured network_type,
- physical_network and segmentation_id
+ :param netconf_override: dict() containing the reconfigured
+ network_type, physical_network and
+ segmentation_id
"""
-
- network_conf = None
if subnet_name and subnet_cidr:
network_conf = NetworkConfig(
name=net_name, subnet_settings=[