@Test public void shutdownStopsService() { dispatcher.shutdown(); verify(service).shutdown(); }
void shutdown() { if (service instanceof PicassoExecutorService) { service.shutdown(); } downloader.shutdown(); dispatcherThread.quit(); Picasso.HANDLER.post(new Runnable() { @Override public void run() { receiver.unregister(); } }); }
Dispatcher { void shutdown() { if (service instanceof PicassoExecutorService) { service.shutdown(); } downloader.shutdown(); dispatcherThread.quit(); Picasso.HANDLER.post(new Runnable() { @Override public void run() { receiver.unregister(); } }); } }
Dispatcher { void shutdown() { if (service instanceof PicassoExecutorService) { service.shutdown(); } downloader.shutdown(); dispatcherThread.quit(); Picasso.HANDLER.post(new Runnable() { @Override public void run() { receiver.unregister(); } }); } Dispatcher(Context context, ExecutorService service, Handler mainThreadHandler,
      Downloader downloader, Cache cache, Stats stats); }
Dispatcher { void shutdown() { if (service instanceof PicassoExecutorService) { service.shutdown(); } downloader.shutdown(); dispatcherThread.quit(); Picasso.HANDLER.post(new Runnable() { @Override public void run() { receiver.unregister(); } }); } Dispatcher(Context context, ExecutorService service, Handler mainThreadHandler,
      Downloader downloader, Cache cache, Stats stats);  }
Dispatcher { void shutdown() { if (service instanceof PicassoExecutorService) { service.shutdown(); } downloader.shutdown(); dispatcherThread.quit(); Picasso.HANDLER.post(new Runnable() { @Override public void run() { receiver.unregister(); } }); } Dispatcher(Context context, ExecutorService service, Handler mainThreadHandler,
      Downloader downloader, Cache cache, Stats stats);   }