BATCH-1739: add test (passes now showing workaround)

This commit is contained in:
Dave Syer
2011-05-03 08:09:25 +01:00
parent 30d1e9fe38
commit a61a9842ae
2 changed files with 37 additions and 0 deletions

View File

@@ -42,4 +42,15 @@ public class ParentStepFactoryBeanParserTests {
assertTrue("Wrong processor type", chunkProcessor instanceof FaultTolerantChunkProcessor<?,?>);
}
@Test
public void testSkippableAttributes() throws Exception {
ConfigurableApplicationContext context = new ClassPathXmlApplicationContext(
"org/springframework/batch/core/configuration/xml/ParentSkippableStepFactoryBeanParserTests-context.xml");
Object step = context.getBean("s1", Step.class);
assertNotNull("Step not parsed", step);
Object tasklet = ReflectionTestUtils.getField(step, "tasklet");
Object chunkProcessor = ReflectionTestUtils.getField(tasklet, "chunkProcessor");
assertTrue("Wrong processor type", chunkProcessor instanceof FaultTolerantChunkProcessor<?,?>);
}
}