### Question:
BBInputSetup implements JavaDelegate { protected boolean isVlanTagging(Service service, String key) { CollectionResourceCustomization collectionCust = findCatalogNetworkCollection(service, key); if (collectionCust != null) { CollectionResource collectionResource = collectionCust.getCollectionResource(); if (collectionResource != null && collectionResource.getInstanceGroup() != null && collectionResource.getInstanceGroup().getToscaNodeType() != null && collectionResource.getInstanceGroup().getToscaNodeType().contains("NetworkCollection")) { return true; } } return false; }  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 testIsVlanTagging() throws Exception { boolean expected = true; Service service = Mockito.mock(Service.class); String key = "collectionCustId"; NetworkCollectionResourceCustomization networkCollection = new NetworkCollectionResourceCustomization(); networkCollection.setModelCustomizationUUID(key); networkCollection.setCollectionResource(new CollectionResource()); networkCollection.getCollectionResource().setInstanceGroup(new org.onap.so.db.catalog.beans.InstanceGroup()); networkCollection.getCollectionResource().getInstanceGroup() .setToscaNodeType("org.openecomp.resource.cr.NetworkCollectionResource1806"); List<CollectionResourceCustomization> customizations = new ArrayList<>(); customizations.add(networkCollection); doReturn(customizations).when(service).getCollectionResourceCustomizations(); boolean actual = SPY_bbInputSetup.isVlanTagging(service, key); assertEquals("Is Vlan Tagging check.", expected, actual); }