svc.setPreferences(preferencesService);
svc.setBundleContext(bundleContext);
svc.setFeaturesServiceRegistry(featuresRegistry);
svc.addRepository(uri);
Repository[] repositories = svc.listRepositories();
assertNotNull(repositories);
assertEquals(1, repositories.length);
assertNotNull(repositories[0]);
Feature[] features = repositories[0].getFeatures();
assertNotNull(features);