@Test public void typicalStop() { setupContextMock(true, true, true); BeekeeperSchedulerApiary.stop(); verify(runnerMock).destroy(); verify(contextMock).close(); }
@VisibleForTesting public static void stop() { if (context == null) { throw new RuntimeException("Application context has not been started."); } if (runner == null) { throw new RuntimeException("Application runner has not been started."); } runner.destroy(); context.close(); }
BeekeeperSchedulerApiary implements ApplicationContextAware { @VisibleForTesting public static void stop() { if (context == null) { throw new RuntimeException("Application context has not been started."); } if (runner == null) { throw new RuntimeException("Application runner has not been started."); } runner.destroy(); context.close(); } }
BeekeeperSchedulerApiary implements ApplicationContextAware { @VisibleForTesting public static void stop() { if (context == null) { throw new RuntimeException("Application context has not been started."); } if (runner == null) { throw new RuntimeException("Application runner has not been started."); } runner.destroy(); context.close(); }  }
BeekeeperSchedulerApiary implements ApplicationContextAware { @VisibleForTesting public static void stop() { if (context == null) { throw new RuntimeException("Application context has not been started."); } if (runner == null) { throw new RuntimeException("Application runner has not been started."); } runner.destroy(); context.close(); }  static void main(String[] args); @VisibleForTesting static boolean isRunning(); @VisibleForTesting static void stop(); @VisibleForTesting static MeterRegistry meterRegistry(); @VisibleForTesting static void resetStaticContext(); @Override void setApplicationContext(ApplicationContext applicationContext); }
BeekeeperSchedulerApiary implements ApplicationContextAware { @VisibleForTesting public static void stop() { if (context == null) { throw new RuntimeException("Application context has not been started."); } if (runner == null) { throw new RuntimeException("Application runner has not been started."); } runner.destroy(); context.close(); }  static void main(String[] args); @VisibleForTesting static boolean isRunning(); @VisibleForTesting static void stop(); @VisibleForTesting static MeterRegistry meterRegistry(); @VisibleForTesting static void resetStaticContext(); @Override void setApplicationContext(ApplicationContext applicationContext);  }