### Question:
CreateNetworkCollection { public void connectInstanceGroupToCloudRegion(BuildingBlockExecution execution) throws Exception { execution.setVariable("connectInstanceGroupToCloudRegionRollback", false); try { ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID); Collection networkCollection = serviceInstance.getCollection(); aaiNetworkResources.connectInstanceGroupToCloudRegion(networkCollection.getInstanceGroup(), execution.getGeneralBuildingBlock().getCloudRegion()); execution.setVariable("connectInstanceGroupToCloudRegionRollback", true); } catch (Exception ex) { exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex); } }  void buildNetworkCollectionName(BuildingBlockExecution execution); void connectCollectionToInstanceGroup(BuildingBlockExecution execution); void connectInstanceGroupToCloudRegion(BuildingBlockExecution execution); void connectCollectionToServiceInstance(BuildingBlockExecution execution);  }### Answer:
@Test public void connectInstanceGroupToCloudRegionTest() throws Exception { doNothing().when(aaiNetworkResources) .connectInstanceGroupToCloudRegion(serviceInstance.getCollection().getInstanceGroup(), cloudRegion); createNetworkCollection.connectInstanceGroupToCloudRegion(execution); verify(aaiNetworkResources, times(1)) .connectInstanceGroupToCloudRegion(serviceInstance.getCollection().getInstanceGroup(), cloudRegion); }