summaryrefslogtreecommitdiffstats
path: root/tosca2heat
diff options
context:
space:
mode:
authorshangxdy <shang.xiaodong@zte.com.cn>2016-08-15 09:54:52 +0800
committershangxdy <shang.xiaodong@zte.com.cn>2016-08-15 09:54:52 +0800
commit769408d0ed336797f76de5df226d30031ae18887 (patch)
tree37bc74bd4c96eb4bb1a0e86f81c1621a6ffb8b52 /tosca2heat
parent5559b0c06930deb1c7831efe599a1036574f50b3 (diff)
The definition about the sequence of capabilities and requirements in
SubstitutionMappings is error The definition in SubstitutionMappings about SECTION is below: SECTIONS = (NODE_TYPE, CAPABILITIES, REQUIREMENTS) = \ ('node_type', 'requirements', 'capabilities') The order of CAPABILITIES and REQUIREMENTS is reserved. JIRA:PARSER-86 Change-Id: Ib55e737f6ed5b49ea3ab9b5e14f8c57486602e7e Signed-off-by: shangxdy <shang.xiaodong@zte.com.cn>
Diffstat (limited to 'tosca2heat')
-rw-r--r--tosca2heat/tosca-parser/toscaparser/substitution_mappings.py17
1 files changed, 9 insertions, 8 deletions
diff --git a/tosca2heat/tosca-parser/toscaparser/substitution_mappings.py b/tosca2heat/tosca-parser/toscaparser/substitution_mappings.py
index f644808..fe47ae4 100644
--- a/tosca2heat/tosca-parser/toscaparser/substitution_mappings.py
+++ b/tosca2heat/tosca-parser/toscaparser/substitution_mappings.py
@@ -31,7 +31,7 @@ class SubstitutionMappings(object):
implementation of a Node type.
'''
- SECTIONS = (NODE_TYPE, CAPABILITIES, REQUIREMENTS) = \
+ SECTIONS = (NODE_TYPE, REQUIREMENTS, CAPABILITIES) = \
('node_type', 'requirements', 'capabilities')
def __init__(self, sub_mapping_def, nodetemplates, inputs, outputs,
@@ -102,13 +102,14 @@ class SubstitutionMappings(object):
InvalidNodeTypeError(what=node_type_def))
def _validate_inputs(self):
- """validate the inputs of substitution mappings."""
-
- # The inputs in service template which provides substutition mappings
- # must be in properties of node template which is mapped or provide
- # defualt value. Currently the input.name is not restrict to be the
- # same as property name in specification, but they should be equal
- # for current implementation.
+ """validate the inputs of substitution mappings.
+
+ The inputs in service template which provides substutition mappings
+ must be in properties of node template which is mapped or provide
+ defualt value. Currently the input.name is not restrict to be the
+ same as property name in specification, but they should be equal
+ for current implementation.
+ """
# Must provide parameters for required properties of node_type
# This checking is internal(inside SubstitutionMappings)