}
public void testShutdownIsPropagatedToTheExecutorOnDestroy() throws Exception {
MockControl mockScheduledExecutorService = MockControl.createNiceControl(ScheduledExecutorService.class);
final ScheduledExecutorService executor = (ScheduledExecutorService) mockScheduledExecutorService.getMock();
executor.shutdown();
mockScheduledExecutorService.setVoidCallable();
mockScheduledExecutorService.replay();
ScheduledExecutorFactoryBean factory = new ScheduledExecutorFactoryBean() {
protected ScheduledExecutorService createExecutor(int poolSize, ThreadFactory threadFactory, RejectedExecutionHandler rejectedExecutionHandler) {