mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Valery Kharseko
23.53.2024 88aec8f06faa1d39466c46490ee13ce50df76222
opendj-grizzly/src/test/java/org/forgerock/opendj/grizzly/ConnectionFactoryTestCase.java
@@ -13,6 +13,7 @@
 *
 * Copyright 2010 Sun Microsystems, Inc.
 * Portions Copyright 2011-2016 ForgeRock AS.
 * Portions Copyright 2019-2024 3A Systems, LLC.
 */
package org.forgerock.opendj.grizzly;
@@ -565,12 +566,12 @@
                    assertThat(context.isClosed()).isFalse();
                    if (config.sendDisconnectNotification) {
                        context.disconnect(ResultCode.BUSY, "busy");
                        for(int i=1;i<10 && !context.isClosed() ;i++) {
                           Thread.sleep(100);
                        }
                    } else {
                        context.disconnect();
                    }
                    for(int i=1;i<100 && !context.isClosed() ;i++) {
                        Thread.sleep(100);
                    }
                    assertThat(context.isClosed()).isTrue();
                }
                // Block until remote close is signalled.