Beispiel #1
0
 def _validate_version(self, version):
     if version not in self.VALID_TEMPLATE_VERSIONS:
         ExceptionCollector.appendException(
             InvalidTemplateVersion(what=version,
                                    valid_versions=', '.join(
                                        self.VALID_TEMPLATE_VERSIONS)))
     else:
         if version != 'tosca_simple_yaml_1_0':
             update_definitions(version)
Beispiel #2
0
 def _validate_version(self, version):
     if version not in self.VALID_TEMPLATE_VERSIONS:
         ExceptionCollector.appendException(
             InvalidTemplateVersion(what=version,
                                    valid_versions='", "'.join(
                                        self.VALID_TEMPLATE_VERSIONS)))
     else:
         if version not in self.MAIN_TEMPLATE_VERSIONS:
             update_definitions(version)
Beispiel #3
0
 def _validate_type_version(self, version):
     if version not in self.VALID_TEMPLATE_VERSIONS:
         ExceptionCollector.appendException(
             InvalidTemplateVersion(what=version + ' in ' + self.import_def,
                                    valid_versions=', '.join(
                                        self.VALID_TEMPLATE_VERSIONS)))