diff options
author | stark, steven <steven.stark@att.com> | 2019-11-18 13:45:47 -0800 |
---|---|---|
committer | stark, steven <steven.stark@att.com> | 2019-11-18 14:30:09 -0800 |
commit | 1d281ce111a76c2b056bcaa572c1e929c90237cf (patch) | |
tree | aefc59fd8aae102d60c75aed484750075e892423 /ice_validator/tests/test_network_format.py | |
parent | 0c4e64d87728b89aa9cd4d41d738f5bfe64ceee3 (diff) |
[VVP] Updating vm_type class test to proceed if no cinder
Other minor changes
- updating error message to be more clear for vm_type class
- updating test_network_format to handle nested files w/ no resources
- updating ports.py to handle hardcoded str_replace param/values
Issue-ID: VVP-342
Signed-off-by: stark, steven <steven.stark@att.com>
Change-Id: I63fcda582fe25dcedca87e874327b7ea56fe6ef3
Diffstat (limited to 'ice_validator/tests/test_network_format.py')
-rw-r--r-- | ice_validator/tests/test_network_format.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ice_validator/tests/test_network_format.py b/ice_validator/tests/test_network_format.py index b291c53..23e46f9 100644 --- a/ice_validator/tests/test_network_format.py +++ b/ice_validator/tests/test_network_format.py @@ -79,7 +79,7 @@ def test_network_has_subnet(yaml_file): networks = [] - for k, v in yml["resources"].items(): + for k, v in yml.get("resources", {}).items(): if not has_properties(v) or v.get("type") not in ["OS::Neutron::Net"]: continue # need to check if contrail networks also require subnet @@ -87,7 +87,7 @@ def test_network_has_subnet(yaml_file): # if v.get("type") not in NETWORK_RESOURCE_TYPES: networks.append(k) - for k, v in yml["resources"].items(): + for k, v in yml.get("resources", {}).items(): network_prop = v.get("properties", {}).get("network", {}).get("get_resource") if ( not has_properties(v) |