1 package org.openecomp.sdc.asdctool.impl.validator.tasks.artifacts;
7 import org.openecomp.sdc.be.dao.jsongraph.GraphVertex;
8 import org.openecomp.sdc.be.datatypes.elements.ArtifactDataDefinition;
10 public class ArtifactValidationUtilsTest {
12 private ArtifactValidationUtils createTestSubject() {
13 return new ArtifactValidationUtils();
16 @Test(expected=NullPointerException.class)
17 public void testValidateArtifactsAreInCassandra() throws Exception {
18 ArtifactValidationUtils testSubject;
19 GraphVertex vertex = null;
21 List<ArtifactDataDefinition> artifacts = null;
22 ArtifactsVertexResult result;
25 testSubject = createTestSubject();
26 result = testSubject.validateArtifactsAreInCassandra(vertex, taskName, artifacts);
29 @Test(expected=NullPointerException.class)
30 public void testIsArtifcatInCassandra() throws Exception {
31 ArtifactValidationUtils testSubject;
36 testSubject = createTestSubject();
37 result = testSubject.isArtifcatInCassandra(uniueId);
41 public void testAddRelevantArtifacts() throws Exception {
42 ArtifactValidationUtils testSubject;
43 Map<String, ArtifactDataDefinition> artifactsMap = null;
44 List<ArtifactDataDefinition> result;
47 testSubject = createTestSubject();
48 result = testSubject.addRelevantArtifacts(artifactsMap);
51 @Test(expected=NullPointerException.class)
52 public void testValidateTopologyTemplateArtifacts() throws Exception {
53 ArtifactValidationUtils testSubject;
54 GraphVertex vertex = null;
56 ArtifactsVertexResult result;
59 testSubject = createTestSubject();
60 result = testSubject.validateTopologyTemplateArtifacts(vertex, taskName);