@Test public void shouldGetAllProviders() { List<TaskDataProvider> expected = new ArrayList<>(); expected.add(new TaskDataProvider()); expected.add(new TaskDataProvider()); when(dataProviderDataService.retrieveAll()).thenReturn(expected); assertEquals(expected, taskDataProviderService.getProviders()); }
@Override @Transactional public List<TaskDataProvider> getProviders() { return dataProviderDataService.retrieveAll(); }
TaskDataProviderServiceImpl implements TaskDataProviderService, OsgiServiceLifecycleListener { @Override @Transactional public List<TaskDataProvider> getProviders() { return dataProviderDataService.retrieveAll(); } }
TaskDataProviderServiceImpl implements TaskDataProviderService, OsgiServiceLifecycleListener { @Override @Transactional public List<TaskDataProvider> getProviders() { return dataProviderDataService.retrieveAll(); } @Autowired  TaskDataProviderServiceImpl(EventRelay eventRelay);  TaskDataProviderServiceImpl(EventRelay eventRelay, MotechJsonReader motechJsonReader); }
TaskDataProviderServiceImpl implements TaskDataProviderService, OsgiServiceLifecycleListener { @Override @Transactional public List<TaskDataProvider> getProviders() { return dataProviderDataService.retrieveAll(); } @Autowired  TaskDataProviderServiceImpl(EventRelay eventRelay);  TaskDataProviderServiceImpl(EventRelay eventRelay, MotechJsonReader motechJsonReader); @Override @Transactional void registerProvider(final String body); @Override @Transactional void registerProvider(final InputStream stream); @Override @Transactional TaskDataProvider getProvider(String name); @Override @Transactional TaskDataProvider getProviderById(Long providerId); @Override @Transactional List<TaskDataProvider> getProviders(); @Override @Transactional void bind(Object service, Map properties); @Override void unbind(Object service, Map properties); @Override @Transactional void unregister(String providerName); }
TaskDataProviderServiceImpl implements TaskDataProviderService, OsgiServiceLifecycleListener { @Override @Transactional public List<TaskDataProvider> getProviders() { return dataProviderDataService.retrieveAll(); } @Autowired  TaskDataProviderServiceImpl(EventRelay eventRelay);  TaskDataProviderServiceImpl(EventRelay eventRelay, MotechJsonReader motechJsonReader); @Override @Transactional void registerProvider(final String body); @Override @Transactional void registerProvider(final InputStream stream); @Override @Transactional TaskDataProvider getProvider(String name); @Override @Transactional TaskDataProvider getProviderById(Long providerId); @Override @Transactional List<TaskDataProvider> getProviders(); @Override @Transactional void bind(Object service, Map properties); @Override void unbind(Object service, Map properties); @Override @Transactional void unregister(String providerName);  }