8358633: Test ThreadPoolExecutorTest::testTimedInvokeAnyNullTimeUnit is broken by JDK-8347491

Reviewed-by: alanb
This commit is contained in:
Viktor Klang 2025-06-05 12:04:57 +00:00
parent 6cdfd36ac8
commit 782bbca439

View File

@ -1727,7 +1727,7 @@ public class ThreadPoolExecutorTest extends JSR166TestCase {
e.invokeAny(l, randomTimeout(), null); e.invokeAny(l, randomTimeout(), null);
shouldThrow(); shouldThrow();
} catch (NullPointerException success) { } catch (NullPointerException success) {
assertEquals("Cannot invoke \"java.util.concurrent.TimeUnit.toNanos(long)\" because \"unit\" is null", success.getMessage()); // Do not check the message, as ThreadPoolExecutor does not override invokeAny
} }
} }
} }