@Test public void assertShutdownJobIfShutdown() throws NoSuchFieldException, SchedulerException { ReflectionUtils.setFieldValue(jobScheduleController, "scheduler", scheduler); when(scheduler.isShutdown()).thenReturn(true); jobScheduleController.shutdown(); verify(schedulerFacade).releaseJobResource(); verify(scheduler, times(0)).shutdown(); }
public void shutdown() { schedulerFacade.releaseJobResource(); try { if (!scheduler.isShutdown()) { scheduler.shutdown(); } } catch (final SchedulerException ex) { throw new JobException(ex); } }
JobScheduleController { public void shutdown() { schedulerFacade.releaseJobResource(); try { if (!scheduler.isShutdown()) { scheduler.shutdown(); } } catch (final SchedulerException ex) { throw new JobException(ex); } } }
JobScheduleController { public void shutdown() { schedulerFacade.releaseJobResource(); try { if (!scheduler.isShutdown()) { scheduler.shutdown(); } } catch (final SchedulerException ex) { throw new JobException(ex); } }  }
JobScheduleController { public void shutdown() { schedulerFacade.releaseJobResource(); try { if (!scheduler.isShutdown()) { scheduler.shutdown(); } } catch (final SchedulerException ex) { throw new JobException(ex); } }  void scheduleJob(final String cronExpression); void rescheduleJob(final String cronExpression); Date getNextFireTime(); void pauseJob(); void resumeJob(); void triggerJob(); void shutdown(); }
JobScheduleController { public void shutdown() { schedulerFacade.releaseJobResource(); try { if (!scheduler.isShutdown()) { scheduler.shutdown(); } } catch (final SchedulerException ex) { throw new JobException(ex); } }  void scheduleJob(final String cronExpression); void rescheduleJob(final String cronExpression); Date getNextFireTime(); void pauseJob(); void resumeJob(); void triggerJob(); void shutdown();  }