Services services = new Services(serviceFactories);
assertSame(messageService, services.getMessageService());
}
public void testPersistenceService() {
Map serviceFactories = new HashMap();
DbPersistenceService persistenceService = new DbPersistenceService(new DbPersistenceServiceFactory());
serviceFactories.put("persistence", new TestGivenServiceFactory(
persistenceService
));
Services services = new Services(serviceFactories);
assertSame(persistenceService, services.getPersistenceService());