EasyMock.expectLastCall().andReturn(Arrays.asList(jobInstance));
jobExplorer.getJobExecutions(jobInstance);
EasyMock.expectLastCall().andReturn(Arrays.asList(jobExecution));
EasyMock.replay(jobExplorer);
JobLaunchRequest request = adapter.adapt("foo");
assertEquals("foo", request.getJob().getName());
assertEquals(0, request.getJobParameters().getParameters().size());
EasyMock.verify(jobExplorer);
}