@After
 @SuppressForbidden(reason = "resets java.io.tmpdir")
 public void tearDown() throws Exception {
   System.setProperty("java.io.tmpdir", javaIoTmpdir);
   PathUtilsForTesting.teardown();
   super.tearDown();
 }
 @Override
 @After
 public void tearDown() throws Exception {
   super.tearDown();
   for (MockNode curNode : nodes.values()) {
     curNode.service.close();
   }
   terminate(threadPool);
 }
 @Override
 public void setUp() throws Exception {
   super.setUp();
   Settings settings =
       Settings.builder()
           .put(Environment.PATH_HOME_SETTING.getKey(), createTempDir().toString())
           .build();
   registry =
       new AnalysisRegistry(
           new Environment(settings), emptyMap(), emptyMap(), emptyMap(), emptyMap(), emptyMap());
 }
 @Override
 @Before
 public void setUp() throws Exception {
   super.setUp();
   this.transport = new MockTransport();
   transportService =
       new TransportService(
           Settings.EMPTY,
           transport,
           THREAD_POOL,
           TransportService.NOOP_TRANSPORT_INTERCEPTOR,
           null);
   transportService.start();
   transportService.acceptIncomingRequests();
 }
  @Before
  @Override
  public void setUp() throws Exception {
    super.setUp();
    threadPool =
        new TestThreadPool(getTestName()) {
          @Override
          public Executor executor(String name) {
            return Runnable::run;
          }

          @Override
          public ScheduledFuture<?> schedule(TimeValue delay, String name, Runnable command) {
            command.run();
            return null;
          }
        };
    retries = 0;
    searchRequest = new SearchRequest();
    searchRequest.scroll(timeValueMinutes(5));
    searchRequest.source(new SearchSourceBuilder().size(10).version(true).sort("_doc").size(123));
    retriesAllowed = 0;
  }
 @Override
 @Before
 public void setUp() throws Exception {
   super.setUp();
   threadPool = new TestThreadPool(getClass().getName());
 }
 @Override
 @After
 public void tearDown() throws Exception {
   transportService.stop();
   super.tearDown();
 }
 @Override
 public void tearDown() throws Exception {
   super.tearDown();
   ThreadPool.terminate(threadPool, 30, TimeUnit.SECONDS);
 }
 @After
 public void tearDown() throws Exception {
   clusterService.close();
   super.tearDown();
 }
 @Before
 public void setUp() throws Exception {
   super.setUp();
   clusterService = createTimedClusterService(true);
 }
 @Override
 @After
 public void tearDown() throws Exception {
   super.tearDown();
   terminate(injector.getInstance(ThreadPool.class));
 }
 public CloseableDirectory(BaseDirectoryWrapper dir) {
   this.dir = dir;
   this.failureMarker = ESTestCase.getSuiteFailureMarker();
 }
 @After
 @Override
 public void tearDown() throws Exception {
   super.tearDown();
   terminate(threadPool);
 }