Spring Batch JUnit test for multiple jobs

前端 未结 5 2010
情深已故
情深已故 2020-12-16 20:24

I am having two jobs configured in one context file


        
            <         


        
5条回答
  •  感情败类
    2020-12-16 20:42

    Not answer to original problem, but using below code we have avoided reuse of JobLauncherTestUtils during sequential run of test cases in same class.

    @DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_EACH_TEST_METHOD)
    

    This indicates Junit to clean up and re construct context after each run.

提交回复
热议问题