### Question:
BBInputSetup implements JavaDelegate { protected List<VolumeGroup> mapVolumeGroups(List<AAIResultWrapper> volumeGroups) { List<VolumeGroup> volumeGroupsList = new ArrayList<>(); for (AAIResultWrapper volumeGroupWrapper : volumeGroups) { volumeGroupsList.add(this.mapVolumeGroup(volumeGroupWrapper)); } return volumeGroupsList; }  BBInputSetupUtils getBbInputSetupUtils(); void setCloudInfoFromAAI(CloudInfoFromAAI cloudInfoFromAAI); void setBbInputSetupUtils(BBInputSetupUtils bbInputSetupUtils); BBInputSetupMapperLayer getMapperLayer(); void setMapperLayer(BBInputSetupMapperLayer mapperLayer); @Override void execute(DelegateExecution execution); ServiceInstance getExistingServiceInstance(org.onap.aai.domain.yang.ServiceInstance serviceInstanceAAI);  }### Answer:
@Test public void testMapVolumeGroups() throws JsonProcessingException { org.onap.aai.domain.yang.VolumeGroup expectedAAI = new org.onap.aai.domain.yang.VolumeGroup(); VolumeGroup expected = new VolumeGroup(); AAIResultWrapper vnfWrapper = new AAIResultWrapper(new AAICommonObjectMapperProvider().getMapper().writeValueAsString(expectedAAI)); doReturn(expected).when(bbInputSetupMapperLayer) .mapAAIVolumeGroup(isA(org.onap.aai.domain.yang.VolumeGroup.class)); List<VolumeGroup> volumeGroupsList = SPY_bbInputSetup.mapVolumeGroups(Arrays.asList(new AAIResultWrapper[] {vnfWrapper})); assertEquals(expected, volumeGroupsList.get(0)); }