mirror of
https://github.com/apache/cloudstack.git
synced 2025-12-16 10:32:34 +01:00
fixed indentaion problem in utils.py :359
Conflicts: tools/marvin/marvin/integration/lib/utils.py
This commit is contained in:
parent
d05891afa1
commit
011b87eadc
@ -329,11 +329,10 @@ def is_snapshot_on_nfs(apiclient, dbconn, config, zoneid, snapshotid):
|
|||||||
(config.mgtSvr[0].mgtSvrIp, e))
|
(config.mgtSvr[0].mgtSvrIp, e))
|
||||||
return 'snapshot exists' in result
|
return 'snapshot exists' in result
|
||||||
|
|
||||||
|
|
||||||
def validateList(inp):
|
def validateList(inp):
|
||||||
'''
|
"""
|
||||||
@name: validateList
|
@name: validateList
|
||||||
@Description: 1. A utility function to validate
|
@Description: 1. A utility function to validate
|
||||||
whether the input passed is a list
|
whether the input passed is a list
|
||||||
2. The list is empty or not
|
2. The list is empty or not
|
||||||
3. If it is list and not empty, return PASS and first element
|
3. If it is list and not empty, return PASS and first element
|
||||||
@ -350,18 +349,18 @@ def validateList(inp):
|
|||||||
default to None.
|
default to None.
|
||||||
INVALID_INPUT
|
INVALID_INPUT
|
||||||
EMPTY_LIST
|
EMPTY_LIST
|
||||||
'''
|
"""
|
||||||
ret = [FAIL, None, None]
|
ret = [FAIL, None, None]
|
||||||
if inp is None:
|
if inp is None:
|
||||||
ret[2] = INVALID_INPUT
|
ret[2] = INVALID_INPUT
|
||||||
return ret
|
return ret
|
||||||
if not isinstance(inp, list):
|
if not isinstance(inp, list):
|
||||||
ret[2] = INVALID_INPUT
|
ret[2] = INVALID_INPUT
|
||||||
return ret
|
return ret
|
||||||
if len(inp) == 0:
|
if len(inp) == 0:
|
||||||
ret[2] = EMPTY_LIST
|
ret[2] = EMPTY_LIST
|
||||||
return ret
|
return ret
|
||||||
return [PASS, inp[0], None]
|
return [PASS, inp[0], None]
|
||||||
|
|
||||||
def verifyElementInList(inp, toverify, responsevar=None, pos=0):
|
def verifyElementInList(inp, toverify, responsevar=None, pos=0):
|
||||||
'''
|
'''
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user