RESOLVED - BATCH-571: Remove reference to Step from StepExecution and reference to Job from JobInstance

JobInstance's reference to Job replaced with jobName string
This commit is contained in:
robokaso
2008-04-28 12:09:54 +00:00
parent 6ca877c1d9
commit 58375f3198
25 changed files with 72 additions and 91 deletions

View File

@@ -6,7 +6,6 @@ import org.springframework.batch.core.JobParameters;
import org.springframework.batch.core.StepExecution;
import org.springframework.batch.item.ExecutionContext;
import org.springframework.batch.sample.item.writer.StagingItemWriter;
import org.springframework.batch.sample.tasklet.JobSupport;
import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests;
import org.springframework.util.ClassUtils;
@@ -37,7 +36,7 @@ public class StagingItemReaderTests extends AbstractTransactionalDataSourceSprin
*/
protected void onSetUpBeforeTransaction() throws Exception {
StepExecution stepExecution = new StepExecution("stepName", new JobExecution(new JobInstance(jobId,
new JobParameters(), new JobSupport("testJob"))));
new JobParameters(), "testJob")));
reader.beforeStep(stepExecution);
writer.beforeStep(stepExecution);
}

View File

@@ -19,7 +19,6 @@ import org.springframework.batch.core.JobExecution;
import org.springframework.batch.core.JobInstance;
import org.springframework.batch.core.JobParameters;
import org.springframework.batch.core.StepExecution;
import org.springframework.batch.sample.tasklet.JobSupport;
import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests;
import org.springframework.util.ClassUtils;
@@ -42,7 +41,7 @@ public class StagingItemWriterTests extends AbstractTransactionalDataSourceSprin
*/
protected void onSetUpBeforeTransaction() throws Exception {
StepExecution stepExecution = new StepExecution("stepName", new JobExecution(new JobInstance(new Long(12L),
new JobParameters(), new JobSupport("testJob"))));
new JobParameters(), "testJob")));
writer.beforeStep(stepExecution);
}