DistanceRepositoryImpl implements DistanceRepository { @Override public void deleteAll() { distanceRepository.deleteAll(); } @Autowired  DistanceRepositoryImpl(DistanceCrudRepository distanceRepository); @Override void saveDistance(Location from, Location to, long distance); @Override long getDistance(Location from, Location to); @Override void deleteDistances(Location location); @Override void deleteAll();  }
@Test void should_delete_all_distances() { repository.deleteAll(); verify(crudRepository).deleteAll(); }