diff --git a/server/src/main/java/org/elasticsearch/threadpool/ThreadPool.java b/server/src/main/java/org/elasticsearch/threadpool/ThreadPool.java index e15a0207abac7..9eb994896cbff 100644 --- a/server/src/main/java/org/elasticsearch/threadpool/ThreadPool.java +++ b/server/src/main/java/org/elasticsearch/threadpool/ThreadPool.java @@ -1086,13 +1086,6 @@ public static boolean assertCurrentThreadPool(String... permittedThreadPoolNames return true; } - public static boolean assertTestThreadPool() { - final var threadName = Thread.currentThread().getName(); - final var executorName = EsExecutors.executorName(threadName); - assert threadName.startsWith("TEST-") || threadName.startsWith("LuceneTestCase") : threadName + " is not a test thread"; - return true; - } - public static boolean assertInSystemContext(ThreadPool threadPool) { final var threadName = Thread.currentThread().getName(); assert threadName.startsWith("TEST-") || threadName.startsWith("LuceneTestCase") || threadPool.getThreadContext().isSystemContext()