ServicesHelper { public List<String> getDomainProviderNames() { List<String> names = new ArrayList<String>(); List<DomainProvider> domainProvider = getDomainProvider(); for (DomainProvider provider : domainProvider) { String name = provider.getName().getString(Locale.getDefault()); names.add(name); } return names; } ServicesHelper(); void init(); void listRunningServices(); List<DomainProvider> getDomainProvider(); List<String> getDomainProviderNames(); void deleteService(String id, boolean force); List<String> getRunningServiceIds(); void createService(String domainProviderName, boolean force, Map<String, String> attributes); void setOsgiUtilsService(DefaultOsgiUtilsService osgiUtilsService); BundleContext getBundleContext(); void setBundleContext(BundleContext bundleContext);  }
@Test public void testGetDomainProviderNames_shouldReturnProviderNames() throws Exception { List<String> domainProviderNames = serviceHelper.getDomainProviderNames(); assertTrue(domainProviderNames.contains("Dummy Name")); }