JobExecutor implements AutoCloseable { public List<Future<JobReport>> submitAll(Job... jobs) { return submitAll(Arrays.asList(jobs)); } JobExecutor();  JobExecutor(int nbWorkers);  JobExecutor(ExecutorService executorService); JobReport execute(Job job); Future<JobReport> submit(Job job); List<Future<JobReport>> submitAll(Job... jobs); List<Future<JobReport>> submitAll(List<Job> jobs); void shutdown(); void awaitTermination(long timeout, TimeUnit unit); @Override void close();  }
@Test public void submitAll() throws Exception { jobExecutor.submitAll(job, anotherJob); verify(executorService).invokeAll(asList(job, anotherJob)); }