Spring batch scope issue while using spring boot
I'm having Standalone spring batch job. This works perfectly fine when in JUNIT @RunWith(SpringJUnit4ClassRunner.class) //@SpringApplicationConfiguration(classes = KPBootApplication.class) @ContextConfiguration(locations={"classpath:kp-sb.xml"}) public class KPBootApplicationTests { private final static Logger LOG=LoggerFactory.getLogger(KPBootApplicationTests.class); @Autowired ApplicationContext context; @Autowired private JobLauncher jobLauncher; @Autowired private Job job; @Test public void testJob() { final JobParameters jobParameters = new JobParametersBuilder() .toJobParameters();