BatchToResourceMapper { public static List<JobInstance> mapInstances(final Collection<org.springframework.batch.core.JobInstance> jobInstances) { final List<JobInstance> response = new LinkedList<>(); for (final org.springframework.batch.core.JobInstance jobInstance : jobInstances) { response.add(map(jobInstance)); } return response; } private  BatchToResourceMapper(); static List<JobExecution> mapExecutions(final Collection<org.springframework.batch.core.JobExecution>
                                                           jobExecutions); static JobExecution map(final org.springframework.batch.core.JobExecution jobExecution); static List<JobInstance> mapInstances(final Collection<org.springframework.batch.core.JobInstance>
                                                         jobInstances); static JobInstance map(final org.springframework.batch.core.JobInstance jobInstance); static JobParameters map(final org.springframework.batch.core.JobParameters jobParameters); static StepExecution map(final org.springframework.batch.core.StepExecution stepExecution); static ExitStatus map(final org.springframework.batch.core.ExitStatus exitStatus); static BatchStatus map(final org.springframework.batch.core.BatchStatus batchStatus); static ParameterType map(final org.springframework.batch.core.JobParameter.ParameterType parameterType);  }
@Test public void testMapJobInstances() { final int count = 5; final List<org.springframework.batch.core.JobInstance> jobInstances = new LinkedList<>(); for (int i = 0; i < count; i++) { final org.springframework.batch.core.JobInstance jobInstance = DomainTestHelper.createJobInstance(1L, "testJob"); jobInstances.add(jobInstance); } final List<JobInstance> result = BatchToResourceMapper.mapInstances(jobInstances); assertThat(result).hasSize(count); }