OPEN - issue BATCH-364: StepScope responsibilities can be assumed by Step (not ApplicationContext)
http://jira.springframework.org/browse/BATCH-364 Instead of lazy open, throw exception is stream is used before open().
This commit is contained in:
@@ -29,9 +29,7 @@ import org.springframework.test.AbstractDependencyInjectionSpringContextTests;
|
||||
* Abstract unit test for running functional tests by getting context locations
|
||||
* for both the container and configuration separately and having them auto
|
||||
* wired in by type. This allows the two to be completely separated, and remove
|
||||
* any 'configuration coupling' between the two. However, it is still purely
|
||||
* theoretical until a decision is made as to how job configuration and
|
||||
* container configuration files are pulled together.
|
||||
* any 'configuration coupling' between the two.
|
||||
*
|
||||
* @author Lucas Ward
|
||||
*
|
||||
|
||||
@@ -60,6 +60,8 @@ public class FixedLengthImportJobFunctionalTests extends AbstractValidatingBatch
|
||||
* @throws Exception
|
||||
*/
|
||||
protected void validatePostConditions() throws Exception {
|
||||
|
||||
inputSource.open();
|
||||
|
||||
jdbcTemplate.query("SELECT ID, ISIN, QUANTITY, PRICE, CUSTOMER FROM trade ORDER BY id", new RowCallbackHandler() {
|
||||
|
||||
|
||||
@@ -48,6 +48,7 @@ public class StagingItemReaderTests extends AbstractTransactionalDataSourceSprin
|
||||
writer.write("BAR");
|
||||
writer.write("SPAM");
|
||||
writer.write("BUCKET");
|
||||
provider.open();
|
||||
}
|
||||
|
||||
protected void onTearDownAfterTransaction() throws Exception {
|
||||
|
||||
Reference in New Issue
Block a user