Add Voluptuous to validate the action parameters
We want a simplest way to validate the input parameters of an Action through a schema. APIImpact DocImpact Partially implements: blueprint watcher-add-actions-via-conf Change-Id: I139775f467fe7778c7354b0cfacf796fc27ffcb2
This commit is contained in:
committed by
Vincent Françoise
parent
33ee575936
commit
e3198d25a5
@@ -84,10 +84,12 @@ def get_test_action(**kwargs):
|
||||
'uuid': kwargs.get('uuid', '10a47dd1-4874-4298-91cf-eff046dbdb8d'),
|
||||
'action_plan_id': kwargs.get('action_plan_id', 1),
|
||||
'action_type': kwargs.get('action_type', 'nop'),
|
||||
'applies_to': kwargs.get('applies_to',
|
||||
'10a47dd1-4874-4298-91cf-eff046dbdb8d'),
|
||||
'input_parameters': kwargs.get('input_parameters', {'key1': 'val1',
|
||||
'key2': 'val2'}),
|
||||
'input_parameters':
|
||||
kwargs.get('input_parameters',
|
||||
{'key1': 'val1',
|
||||
'key2': 'val2',
|
||||
'resource_id':
|
||||
'10a47dd1-4874-4298-91cf-eff046dbdb8d'}),
|
||||
'state': kwargs.get('state', 'PENDING'),
|
||||
'alarm': kwargs.get('alarm', None),
|
||||
'next': kwargs.get('next', 2),
|
||||
|
||||
Reference in New Issue
Block a user