Skip to content

Commit 29445ad

Browse files
authored
[#748] stabilize flaky GrizzlyLDAPConnectionFactoryTestCase.testResourceManagement (#749)
1 parent b297c2f commit 29445ad

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

opendj-grizzly/src/test/java/org/forgerock/opendj/grizzly/GrizzlyLDAPConnectionFactoryTestCase.java

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
* information: "Portions Copyright [year] [name of copyright owner]".
1313
*
1414
* Copyright 2013-2016 ForgeRock AS.
15+
* Portions Copyrighted 2026 3A Systems, LLC
1516
*/
1617
package org.forgerock.opendj.grizzly;
1718

@@ -86,8 +87,16 @@ public class GrizzlyLDAPConnectionFactoryTestCase extends SdkTestCase {
8687
*/
8788
private static final int ITERATIONS = 100;
8889

89-
/** Test timeout for tests which need to wait for network events. */
90-
private static final long TEST_TIMEOUT = 30L;
90+
/**
91+
* Test timeout for tests which need to wait for network events. This is a
92+
* generous upper bound rather than an expected duration: in the normal case
93+
* the awaited latch/promise is released within milliseconds. It only takes
94+
* effect when a CI runner is slow enough to delay delivery of an async
95+
* event (see issue #748, where {@code testResourceManagement} timed out on
96+
* a loaded macOS/Java 11 runner), so a larger value trades a slower failure
97+
* for far fewer false-negative builds.
98+
*/
99+
private static final long TEST_TIMEOUT = 60L;
91100

92101
/*
93102
* It is usually quite a bad code smell to share state between unit tests.

0 commit comments

Comments
 (0)