### Question:
NetworkBBUtils { public String getCloudRegion(BuildingBlockExecution execution, SourceSystem sourceValue) { GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock(); CloudRegion cloudRegion = gBBInput.getCloudRegion(); String cloudRegionId = cloudRegion.getLcpCloudRegionId(); if (sourceValue.equals(SourceSystem.SDNC) && CLOUD_REGION_VER25.equalsIgnoreCase(cloudRegion.getCloudRegionVersion())) { cloudRegionId = CLOUD_REGION_AAIAIC25; } return cloudRegionId; }  boolean isRelationshipRelatedToExists(Optional<org.onap.aai.domain.yang.L3Network> l3network,
            String relatedToValue); String getCloudRegion(BuildingBlockExecution execution, SourceSystem sourceValue);  }### Answer:
@Test public void getCloudRegionSDNC25Test() throws Exception { cloudRegion.setCloudRegionVersion("2.5"); NetworkBBUtils spyAssign = Mockito.spy(NetworkBBUtils.class); String cloudRegionId = spyAssign.getCloudRegion(execution, SourceSystem.SDNC); Mockito.verify(spyAssign).getCloudRegion(execution, SourceSystem.SDNC); assertEquals("AAIAIC25", cloudRegionId); }
@Test public void getCloudRegionSDNC30Test() throws Exception { cloudRegion.setCloudRegionVersion("3.0"); NetworkBBUtils spyAssign = Mockito.spy(NetworkBBUtils.class); String cloudRegionId = spyAssign.getCloudRegion(execution, SourceSystem.SDNC); Mockito.verify(spyAssign).getCloudRegion(execution, SourceSystem.SDNC); assertEquals(cloudRegion.getLcpCloudRegionId(), cloudRegionId); }
@Test public void getCloudRegionPO25Test() throws Exception { cloudRegion.setCloudRegionVersion("2.5"); NetworkBBUtils spyAssign = Mockito.spy(NetworkBBUtils.class); String cloudRegionId = spyAssign.getCloudRegion(execution, SourceSystem.PO); Mockito.verify(spyAssign).getCloudRegion(execution, SourceSystem.PO); assertEquals(cloudRegion.getLcpCloudRegionId(), cloudRegionId); }
@Test public void getCloudRegionPO30Test() throws Exception { cloudRegion.setCloudRegionVersion("3.0"); NetworkBBUtils spyAssignPO = Mockito.spy(NetworkBBUtils.class); String cloudRegionIdPO = spyAssignPO.getCloudRegion(execution, SourceSystem.PO); Mockito.verify(spyAssignPO).getCloudRegion(execution, SourceSystem.PO); assertEquals(cloudRegion.getLcpCloudRegionId(), cloudRegionIdPO); }