CoreComponentProvider extends AbstractComponentProvider implements DefaultComponentProvider { @Override public Collection<ComponentTypeInfo> getComponentTypes() { List<ComponentTypeInfo> compInfos = new ArrayList<ComponentTypeInfo>(); ComponentTypeInfo typeInfo = new ComponentTypeInfo(resource.getString("discipline_component_display_name"), resource .getString("discipline_component_description"), TelemetryDisciplineComponent.class, false); compInfos.add(typeInfo); typeInfo = new ComponentTypeInfo(resource.getString("user_dropbox_component_display_name"), resource .getString("user_dropbox_component_description"), TelemetryUserDropBoxComponent.class, false); compInfos.add(typeInfo); typeInfo = new ComponentTypeInfo(resource.getString("mine_component_display_name"), resource .getString("mine_component_description"), MineTaxonomyComponent.class, false); compInfos.add(typeInfo); typeInfo = new ComponentTypeInfo(resource.getString("broken_component_display_name"), resource .getString("broken_component_description"), BrokenComponent.class, false); compInfos.add(typeInfo); typeInfo = new ComponentTypeInfo(resource.getString("data_taxonomy_component_type_display_name"), resource.getString("data_taxonomy_component_type_description"), TelemetryDataTaxonomyComponent.class, false); compInfos.add(typeInfo); return compInfos; }  @Override Collection<ComponentTypeInfo> getComponentTypes(); @Override Collection<ViewInfo> getViews(String componentTypeId); @Override Collection<PolicyInfo> getPolicyInfos(); @Override Class<? extends AbstractComponent> getBrokenComponent(); @Override AbstractComponent createDropbox(String userId); @Override AbstractComponent createSandbox(String userId); @Override void createDefaultComponents(); @Override ProviderDelegate getProviderDelegate(); @Override T getAsset(TypeInfo<?> typeInfo, Class<T> assetClass);  }
@Test (dataProvider="componentTypesTestCases") public void testComponentTypes(Class<?> expectedType) { Collection<ComponentTypeInfo> typeInfos = provider.getComponentTypes(); boolean found = false; for (TypeInfo<?> t : typeInfos) { found |= t.getTypeClass().equals(expectedType); } Assert.assertTrue(found); }