diff options
author | 2018-03-18 20:07:39 +0200 | |
---|---|---|
committer | 2018-03-18 20:07:39 +0200 | |
commit | 545434fd679fa918288b913a6525d2e05777b22a (patch) | |
tree | 43c3af6f76a3d6a1a3cebebac082943ae879c19b /vid-app-common/src/test/java/org/onap/vid/services | |
parent | 8fdf2dee7684f4911a58a2350626300af52b6e4d (diff) |
Unit tests
Change-Id: I43cd9c20e5576a63a0d0f9e78a91c27fcf32b2ad
Issue-ID: VID-197
Signed-off-by: Sonsino, Ofir (os0695) <os0695@intl.att.com>
Diffstat (limited to 'vid-app-common/src/test/java/org/onap/vid/services')
-rw-r--r-- | vid-app-common/src/test/java/org/onap/vid/services/ChangeManagementServiceImplTest.java | 81 |
1 files changed, 79 insertions, 2 deletions
diff --git a/vid-app-common/src/test/java/org/onap/vid/services/ChangeManagementServiceImplTest.java b/vid-app-common/src/test/java/org/onap/vid/services/ChangeManagementServiceImplTest.java index 85b88a0d..7819b4c9 100644 --- a/vid-app-common/src/test/java/org/onap/vid/services/ChangeManagementServiceImplTest.java +++ b/vid-app-common/src/test/java/org/onap/vid/services/ChangeManagementServiceImplTest.java @@ -24,7 +24,8 @@ import org.springframework.web.multipart.MultipartFile; public class ChangeManagementServiceImplTest { private ChangeManagementServiceImpl createTestSubject() { - return new ChangeManagementServiceImpl(new DataAccessServiceImpl(), new MsoBusinessLogicImpl(new MsoRestClientNew())); + return new ChangeManagementServiceImpl(new DataAccessServiceImpl(), + new MsoBusinessLogicImpl(new MsoRestClientNew())); } @Test @@ -51,7 +52,6 @@ public class ChangeManagementServiceImplTest { Assert.assertEquals(null, result); } - @Test public void testGetSchedulerChangeManagements() throws Exception { ChangeManagementServiceImpl testSubject; @@ -72,7 +72,84 @@ public class ChangeManagementServiceImplTest { testSubject.deleteSchedule(scheduleId); } + @Test + public void testAddVnfWorkflowRelation() throws Exception { + ChangeManagementServiceImpl testSubject; + VnfWorkflowRelationRequest vnfWorkflowRelationRequest = null; + VnfWorkflowRelationResponse result; + + // default test + try { + testSubject = createTestSubject(); + result = testSubject.addVnfWorkflowRelation(vnfWorkflowRelationRequest); + } catch ( + + Exception e) { + } + } + + @Test + public void testDeleteVnfWorkflowRelation() throws Exception { + ChangeManagementServiceImpl testSubject; + VnfWorkflowRelationRequest vnfWorkflowRelationRequest = null; + VnfWorkflowRelationResponse result; + // default test + try { + testSubject = createTestSubject(); + result = testSubject.deleteVnfWorkflowRelation(vnfWorkflowRelationRequest); + } catch ( + + Exception e) { + } + } + + @Test + public void testGetAllVnfWorkflowRelations() throws Exception { + ChangeManagementServiceImpl testSubject; + VnfWorkflowRelationAllResponse result; + + // default test + try { + testSubject = createTestSubject(); + result = testSubject.getAllVnfWorkflowRelations(); + } catch ( + + Exception e) { + } + } + + @Test + public void testGetWorkflowsForVnf() throws Exception { + ChangeManagementServiceImpl testSubject; + GetVnfWorkflowRelationRequest getVnfWorkflowRelationRequest = null; + List<String> result; + + // default test + try { + testSubject = createTestSubject(); + result = testSubject.getWorkflowsForVnf(getVnfWorkflowRelationRequest); + } catch ( + + Exception e) { + } + } + + @Test + public void testUploadConfigUpdateFile() throws Exception { + ChangeManagementServiceImpl testSubject; + MultipartFile file = null; + String result; + + // default test + try { + testSubject = createTestSubject(); + result = testSubject.uploadConfigUpdateFile(file); + } catch ( + + Exception e) { + } + } /* * TODO: fix private ChangeManagementServiceImpl createTestSubject() { |