Don't put a null value description in the outputs when no description is provided.
Don't create an output if the value is null. Change-Id: I5ea108ec8f0a9c219535cd82fcf7263c9f61f339
This commit is contained in:
parent
a8e2cf59d9
commit
e022a26c32
@ -21,5 +21,8 @@ class HotOutput(object):
|
||||
self.description = description
|
||||
|
||||
def get_dict_output(self):
|
||||
if self.description:
|
||||
return {self.name: {'value': self.value,
|
||||
'description': self.description}}
|
||||
else:
|
||||
return {self.name: {'value': self.value}}
|
||||
|
@ -34,6 +34,7 @@ class TranslateOutputs(object):
|
||||
hot_outputs = []
|
||||
for output in self.outputs:
|
||||
hot_value = self.nodes.translate_param_value(output.value, None)
|
||||
if hot_value is not None:
|
||||
hot_outputs.append(HotOutput(output.name, hot_value,
|
||||
output.description))
|
||||
return hot_outputs
|
||||
|
@ -32,11 +32,10 @@ resources:
|
||||
get_file: myapp_configure.sh
|
||||
outputs:
|
||||
map_val:
|
||||
description: null
|
||||
description: map_val
|
||||
value:
|
||||
get_input: map_val
|
||||
concat_map_val:
|
||||
description: null
|
||||
value:
|
||||
str_replace:
|
||||
params:
|
||||
@ -46,5 +45,4 @@ outputs:
|
||||
get_input: map_val
|
||||
template: $s0$s1$s2
|
||||
static_map_val:
|
||||
description: null
|
||||
value: static_value
|
||||
|
@ -71,6 +71,7 @@ topology_template:
|
||||
|
||||
outputs:
|
||||
map_val:
|
||||
description: map_val
|
||||
value: { get_property: [ myapp, myfeature, my_map, test_key ] }
|
||||
|
||||
static_map_val:
|
||||
|
Loading…
Reference in New Issue
Block a user