summaryrefslogtreecommitdiffstats
path: root/catalog-be/src/test/java
diff options
context:
space:
mode:
authorFrancis Toth <francis.toth@yoppworks.com>2020-05-02 10:16:17 -0400
committerOfir Sonsino <ofir.sonsino@intl.att.com>2020-05-27 06:41:28 +0000
commit18ae7612481c386db22fe983dedf331a29141444 (patch)
treeb197c3e9d16f122dc66bd53c803169ec92a59074 /catalog-be/src/test/java
parent9373e4f17236dc7496cd7dcfbbd159675e839e55 (diff)
Refactor CsarUtils::WriteArtifactDefinition
Signed-off-by: Francis Toth <francis.toth@yoppworks.com> Change-Id: I167a05d8fbc2085a3e25eeb5bfd6b30f0e80462e Issue-ID: SDC-2812
Diffstat (limited to 'catalog-be/src/test/java')
-rw-r--r--catalog-be/src/test/java/org/openecomp/sdc/be/tosca/CsarUtilsTest.java20
1 files changed, 2 insertions, 18 deletions
diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/tosca/CsarUtilsTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/tosca/CsarUtilsTest.java
index 3ee2b89047..4fd8a70229 100644
--- a/catalog-be/src/test/java/org/openecomp/sdc/be/tosca/CsarUtilsTest.java
+++ b/catalog-be/src/test/java/org/openecomp/sdc/be/tosca/CsarUtilsTest.java
@@ -43,6 +43,8 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Optional;
import java.util.Set;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
import java.util.zip.ZipEntry;
import java.util.zip.ZipOutputStream;
import mockit.Deencapsulation;
@@ -781,24 +783,6 @@ public class CsarUtilsTest extends BeConfDependentTest {
}
@Test
- public void testWriteArtifactDefinition() throws IOException {
- Component component = new Service();
- List<ArtifactDefinition> artifactDefinitionList = new ArrayList<>();
- String artifactPathAndFolder = "";
-
- ArtifactDefinition artifact = new ArtifactDefinition();
- artifact.setArtifactType(ArtifactTypeEnum.HEAT_ENV.getType());
- artifactDefinitionList.add(artifact);
-
- try (ByteArrayOutputStream out = new ByteArrayOutputStream(); ZipOutputStream zip = new ZipOutputStream(out);) {
- Either<ZipOutputStream, ResponseFormat> output = Deencapsulation.invoke(testSubject, "writeArtifactDefinition", component, zip, artifactDefinitionList, artifactPathAndFolder, false);
-
- assertNotNull(output);
- assertTrue(output.isLeft());
- }
- }
-
- @Test
public void testCollectComponentCsarDefinitionWhenComponentIsServiceAndGetToscaElementIsLeft() {
Component component = new Service();
component.setUniqueId("uniqueId");