### Question:
AzureKeyVaultClientCredentials extends KeyVaultCredentials { @PreDestroy public void onDestroy() { executorService.shutdown(); } AzureKeyVaultClientCredentials(String clientId, String clientSecret, ExecutorService executorService); @Override String doAuthenticate(String authorization, String resource, String scope); @PreDestroy void onDestroy();  }### Answer:
@Test public void onDestroyShutsDownExecutor() { ExecutorService executorService = mock(ExecutorService.class); credentials = new AzureKeyVaultClientCredentials("id", "secret", executorService); credentials.onDestroy(); verify(executorService).shutdown(); }