StandbyJobServiceImpl extends AbstractService implements StandbyJobService, ApplicationContextAware { @Override public StandbyJob getJob(String group, String name, String jarFileName) { StandbyJob param = new StandbyJob(); param.setGroupName(group); param.setJobName(name); param.setJarFileName(jarFileName); return baseDao.getUnique(StandbyJob.class, param); }  @Override void setApplicationContext(ApplicationContext applicationContext); @Override List<StandbyJob> getAllJobs(); @Override StandbyJob getJob(String group, String name, String jarFileName); @Override void saveJob(String jarFilePath, String packagesToScan); @Override List<String> getJarFileNameList(String group, String name);  }
@Test public void getJob() { standbyJobService.saveJob(getSampleJarFile(), "com.zuoxiaolong"); StandbyJob job = standbyJobService.getJob("com.zuoxiaolong.niubi.job.sample.spring.job.Job1", "test", "niubi-job-sample-spring.jar"); Assert.assertNotNull(job); }