@Test
public void registerSchedulerForJobCronTest() throws NoSuchJobException {

    when(this.jobRegistry.getJob("sampleJob")).thenReturn(this.sampleJob);
    final JobSchedulerConfiguration jobSchedulerConfiguration = DomainTestHelper.createJobSchedulerConfiguration("* * *" +
                    " * * *",
            null, null, JobSchedulerType.CRON);
    final JobConfiguration jobConfiguration = DomainTestHelper.createJobConfiguration(jobSchedulerConfiguration);
    jobConfiguration.setJobConfigurationId(1L);
    final String beanName = this.schedulerService.registerSchedulerForJob(jobConfiguration);
    assertThat(beanName).startsWith("sampleJob-CRON");
}