@Test public void shouldRemoveDonor() throws Exception { service.removeDonor(3L); verify(repository).removeDonor(3L); }
public void removeDonor(Long id){ donorRepository.removeDonor(id); }
DonorService { public void removeDonor(Long id){ donorRepository.removeDonor(id); } }
DonorService { public void removeDonor(Long id){ donorRepository.removeDonor(id); } @Autowired  DonorService(DonorRepository donorRepository); }
DonorService { public void removeDonor(Long id){ donorRepository.removeDonor(id); } @Autowired  DonorService(DonorRepository donorRepository); void save(Donor donor); List<Donor> getAll(); List<Donor> getAllWithDetails(); void removeDonor(Long id); Donor getById(Long donorId); }
DonorService { public void removeDonor(Long id){ donorRepository.removeDonor(id); } @Autowired  DonorService(DonorRepository donorRepository); void save(Donor donor); List<Donor> getAll(); List<Donor> getAllWithDetails(); void removeDonor(Long id); Donor getById(Long donorId);  }