diff options
Diffstat (limited to 'openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test')
5 files changed, 20 insertions, 10 deletions
diff --git a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/java/org/openecomp/core/converter/impl/ToscaConvertorDefinitionsTest.java b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/java/org/openecomp/core/converter/impl/ToscaConvertorDefinitionsTest.java index 82a36950f3..0fec361561 100644 --- a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/java/org/openecomp/core/converter/impl/ToscaConvertorDefinitionsTest.java +++ b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/java/org/openecomp/core/converter/impl/ToscaConvertorDefinitionsTest.java @@ -1,5 +1,16 @@ package org.openecomp.core.converter.impl; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertTrue; +import static org.openecomp.core.converter.datatypes.Constants.ONAP_INDEX; +import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.DEFININTION_VERSION; +import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.GLOBAL_SUBSTITUTION_SERVICE_FILE_NAME; +import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.HEAT_INDEX; +import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.TEMPLATE_NAME_PROPERTY; +import static org.openecomp.sdc.common.utils.CommonUtil.validateAndUploadFileContent; + import org.apache.commons.io.IOUtils; import org.junit.Test; import org.openecomp.core.impl.GlobalSubstitutionServiceTemplate; @@ -12,16 +23,6 @@ import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; import java.net.URL; import java.util.Map; import java.util.Set; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; -import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.DEFININTION_VERSION; -import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.GLOBAL_SUBSTITUTION_SERVICE_FILE_NAME; -import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.HEAT_INDEX; -import static org.openecomp.core.impl.GlobalSubstitutionServiceTemplate.TEMPLATE_NAME_PROPERTY; -import static org.openecomp.sdc.common.utils.CommonUtil.validateAndUploadFileContent; public class ToscaConvertorDefinitionsTest { @@ -48,6 +49,7 @@ public class ToscaConvertorDefinitionsTest { assertFalse(serviceTemplate.getImports().isEmpty()); assertEquals(1 ,serviceTemplate.getImports().size()); assertTrue(serviceTemplate.getImports().get(0).containsKey(HEAT_INDEX)); + assertTrue(serviceTemplate.getImports().get(0).containsKey(ONAP_INDEX)); assertEquals(DEFININTION_VERSION, serviceTemplate.getTosca_definitions_version()); diff --git a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/conversionWithInt/out/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/conversionWithInt/out/MainServiceTemplate.yaml index 10f7c21363..1a5c61efbe 100644 --- a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/conversionWithInt/out/MainServiceTemplate.yaml +++ b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/conversionWithInt/out/MainServiceTemplate.yaml @@ -12,6 +12,8 @@ metadata: imports: - openecomp_heat_index: file: openecomp-heat/_index.yml +- onap_index: + file: onap/_index.yml - GlobalSubstitutionTypes: file: GlobalSubstitutionTypesServiceTemplate.yaml topology_template: diff --git a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertCsar/out/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertCsar/out/MainServiceTemplate.yaml index e54533e7c2..590ee413b8 100644 --- a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertCsar/out/MainServiceTemplate.yaml +++ b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertCsar/out/MainServiceTemplate.yaml @@ -14,6 +14,8 @@ metadata: imports: - openecomp_heat_index: file: openecomp-heat/_index.yml +- onap_index: + file: onap/_index.yml - GlobalSubstitutionTypes: file: GlobalSubstitutionTypesServiceTemplate.yaml topology_template: diff --git a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertMainSt/out/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertMainSt/out/MainServiceTemplate.yaml index ff43b5a7e7..88ae60529d 100644 --- a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertMainSt/out/MainServiceTemplate.yaml +++ b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertMainSt/out/MainServiceTemplate.yaml @@ -13,6 +13,8 @@ metadata: imports: - openecomp_heat_index: file: openecomp-heat/_index.yml +- onap_index: + file: onap/_index.yml - GlobalSubstitutionTypes: file: GlobalSubstitutionTypesServiceTemplate.yaml node_types: diff --git a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertParameters/out/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertParameters/out/MainServiceTemplate.yaml index 8dbe0517f5..d30f46e360 100644 --- a/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertParameters/out/MainServiceTemplate.yaml +++ b/openecomp-be/lib/openecomp-tosca-converter-lib/openecomp-tosca-converter-core/src/test/resources/mock/toscaConverter/convertParameters/out/MainServiceTemplate.yaml @@ -13,6 +13,8 @@ metadata: imports: - openecomp_heat_index: file: openecomp-heat/_index.yml +- onap_index: + file: onap/_index.yml - GlobalSubstitutionTypes: file: GlobalSubstitutionTypesServiceTemplate.yaml topology_template: |