Skip to content

Commit 7225fb6

Browse files
authored
[Test] More accurate pattern matching for testWatchdogLogging (elastic#128648) (elastic#128664)
There might be other thread temporarily not making progress and reported by the watchdog. This PR tightens up the pattern matching for the expected thread name. Resolves: elastic#128646
1 parent 2a657c2 commit 7225fb6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/framework/src/main/java/org/elasticsearch/transport/AbstractSimpleTransportTestCase.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3359,7 +3359,7 @@ public void testWatchdogLogging() {
33593359
MockLog.assertThatLogger(
33603360
deterministicTaskQueue::runAllRunnableTasks,
33613361
ThreadWatchdog.class,
3362-
new MockLog.UnseenEventExpectation("no logging", ThreadWatchdog.class.getCanonicalName(), Level.WARN, "*")
3362+
new MockLog.UnseenEventExpectation("no logging", ThreadWatchdog.class.getCanonicalName(), Level.WARN, "*" + threadName + "*")
33633363
);
33643364
deterministicTaskQueue.advanceTime();
33653365
MockLog.assertThatLogger(

0 commit comments

Comments
 (0)