JSONObject content = new JSONObject(contentStr);
MockDBService dbService = MockDBService.initialise();
Whitebox.invokeMethod(ah, "populateProtocolReference", dbService, content);
+ assertNotNull(ah);
}
@Test
MockDBService dbService = MockDBService.initialise();
SvcLogicContext context = new SvcLogicContext();
artifactHandlerNode.processVmList(content, context, dbService);
+ assertNotNull(contentStr);
}
@Test
SvcLogicContext context = new SvcLogicContext();
context.setAttribute(SdcArtifactHandlerConstants.DEVICE_PROTOCOL, "Test");
artifactHandlerNode.processConfigTypeActions(content, dbService, context);
+ assertNotNull(contentStr);
}
@Test
artifactHandlerNode.processActionLists(content, actionLevel, vnfcActionList, vfModuleActionList,
vnfActionList, vmActionVnfcFunctionCodesList);
}
+ assertNotNull(contentStr);
}
@Test
context.setAttribute("vnf-type", "someVnf");
context.setAttribute("action", "ConfigScaleOut");
artifactHandlerNode.processArtifactList(content, dbService, context, null);
+ assertNotNull(content);
}
@Test
documentInfo.put(SdcArtifactHandlerConstants.ARTIFACT_DESRIPTION, "testArtifactDesc");
Whitebox.invokeMethod(ah, "processAndStoreCapabilitiesArtifact", dbService, documentInfo, capabilities,
"artifactName", "someVnf");
+ assertNotNull(ah);
}
import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
import org.junit.Test;
import org.onap.appc.interfaces.service.executorImpl.ServiceExecutorImpl;
import org.onap.appc.interfaces.service.data.ScopeOverlap;
ServiceExecutorImpl sei = new ServiceExecutorImpl();
String requestData = "{\"vnf-id\":\"ibcx8888v\",\"current-request\" :{\"action\" : \"Audit\",\"action-identifiers\" : {\"service-instance-id\" : \"service-instance-id\",\"vnf-id\" : \"vnf-id\",\"vnfc-name\" : \"vnfc-name\",\"vf-module-id\" : \"vf-module-id\",\"vserver-id\": \"vserver-id\"}},\"in-progress-requests\" :[{\"action\" : \"HealthCheck\",\"action-identifiers\" : {\"service-instance-id\" : \"service-instance-id1\",\"vnf-id\" : \"vnf-id1\",\"vnfc-name\" : \"vnfc-name1\",\"vf-module-id\" : \"vf-module-id\",\"vserver-id\": \"vserver-id1\"}},{\"action\" : \"CheckLock\",\"action-identifiers\" : {\"service-instance-id\" : \"service-instance-id2\",\"vnf-id\" : \"vnf-id2\",\"vnfc-name\" : \"vnfc-name2\",\"vf-module-id\" : \"vf-module-id2\",\"vserver-id\": \"vserver-id2\"}}]}";
sei.isRequestOverLap(requestData);
+ assertNotNull(sei);
}
@Test
import org.powermock.modules.junit4.PowerMockRunner;
import org.powermock.reflect.Whitebox;
+import static org.junit.Assert.assertNotNull;
import static org.mockito.Mockito.mock;
import static org.powermock.api.mockito.PowerMockito.mockStatic;
MaintenanceModeInput mockInput1 = mock(MaintenanceModeInput.class);
Mockito.doReturn(mockCommonHeader).when(mockInput1).getCommonHeader();
operationHelper.isInputValid(mockInput1);
+ assertNotNull(mockInput);
}
@Test