OPEN - issue BATCH-324: Step as factory for StepExecutor

http://jira.springframework.org/browse/BATCH-324

First pass - added factory method, resolved conflicts and cycles, got tests working.
This commit is contained in:
dsyer
2008-01-29 15:07:53 +00:00
parent 6ad596421b
commit 4da4c073d5
32 changed files with 325 additions and 577 deletions

View File

@@ -17,6 +17,7 @@
package org.springframework.batch.sample;
import org.springframework.batch.core.domain.JobParameters;
import org.springframework.batch.io.exception.BatchCriticalException;
import org.springframework.jdbc.core.JdbcOperations;
/**
@@ -68,10 +69,14 @@ public class RestartFunctionalTests extends AbstractBatchLauncherTests {
runJob();
fail("First run of the job is expected to fail.");
}
catch (Exception expected) {
catch (BatchCriticalException expected) {
//expected
assertTrue("Not planned exception: "+expected.getMessage(), expected.getMessage().toLowerCase().indexOf("planned")>=0);
}
int medium = jdbcTemplate.queryForInt("SELECT COUNT(*) FROM TRADE");
System.err.println(medium);
runJob();
int after = jdbcTemplate.queryForInt("SELECT COUNT(*) FROM TRADE");