@Test
public void updateJobConfigurationWithListenerTest() throws NoSuchJobConfigurationException {

    final JobListenerConfiguration jobListenerConfiguration = DomainTestHelper.createJobListenerConfiguration
            ("src/test/", "*.txt", JobListenerType.LOCAL_FOLDER_LISTENER);
    jobListenerConfiguration.setBeanName("testBean");
    final JobConfiguration jobConfiguration = DomainTestHelper.createJobConfiguration(jobListenerConfiguration);
    jobConfiguration.setJobConfigurationId(1L);
    when(this.properties.getApplicationName()).thenReturn(APPLICATION_NAME);
    when(this.jobConfigurationRepository.getJobConfiguration(jobConfiguration.getJobConfigurationId(), APPLICATION_NAME)).thenReturn(jobConfiguration);
    try {
        this.defaultAdminService.updateJobConfiguration(jobConfiguration);
    } catch (final SpringBatchLightminApplicationException e) {
        fail(e.getMessage());
    }
}