summary |
shortlog |
log |
commit | commitdiff |
review |
tree
raw |
patch |
inline | side by side (from parent 1:
1d319a4)
Change-Id: I18a9802c643f778c2aedb658848c091ff8a1587c
Issue-ID: VVP-296
Signed-off-by: Ezhilarasi <ezhrajam@in.ibm.com>
- If more than one vm_type is detected all vm_types will
be returned
"""
- If more than one vm_type is detected all vm_types will
be returned
"""
- if not isinstance(resource, dict):
- return set()
if not is_nova_server(resource):
return set()
if not is_nova_server(resource):
return set()
def is_nova_server(resource):
def is_nova_server(resource):
- return (
- "type" in resource
- and "properties" in resource
- and resource.get("type") == "OS::Nova::Server"
- )
+ return isinstance(resource, dict) and "type" in resource and "properties" in resource and resource.get("type") == "OS::Nova::Server"
def get_vm_type_for_nova_server(resource):
def get_vm_type_for_nova_server(resource):