activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject activemq-artemis git commit: NO-JIRA Improving a test with Wait
Date Wed, 02 Aug 2017 14:41:37 GMT
Repository: activemq-artemis
Updated Branches:
  refs/heads/master bc2670a54 -> c3f8321c4


NO-JIRA Improving a test with Wait


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/c3f8321c
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/c3f8321c
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/c3f8321c

Branch: refs/heads/master
Commit: c3f8321c42e7356357608db5d283d68054aa6466
Parents: bc2670a
Author: Clebert Suconic <clebertsuconic@apache.org>
Authored: Wed Aug 2 10:39:19 2017 -0400
Committer: Clebert Suconic <clebertsuconic@apache.org>
Committed: Wed Aug 2 10:39:19 2017 -0400

----------------------------------------------------------------------
 .../integration/cluster/failover/BackupAuthenticationTest.java    | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/c3f8321c/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/failover/BackupAuthenticationTest.java
----------------------------------------------------------------------
diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/failover/BackupAuthenticationTest.java
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/failover/BackupAuthenticationTest.java
index 9f444a4..822defd 100644
--- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/failover/BackupAuthenticationTest.java
+++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/cluster/failover/BackupAuthenticationTest.java
@@ -27,6 +27,7 @@ import org.apache.activemq.artemis.core.protocol.core.Packet;
 import org.apache.activemq.artemis.core.protocol.core.impl.PacketImpl;
 import org.apache.activemq.artemis.spi.core.protocol.RemotingConnection;
 import org.apache.activemq.artemis.tests.util.TransportConfigurationUtils;
+import org.apache.activemq.artemis.tests.util.Wait;
 import org.junit.Before;
 import org.junit.Test;
 
@@ -51,7 +52,7 @@ public class BackupAuthenticationTest extends FailoverTestBase {
        * can't intercept the message at the backup, so we intercept the registration message
at the
        * live.
        */
-      Thread.sleep(2000);
+      Wait.waitFor(() -> !backupServer.isStarted());
       assertFalse("backup should have stopped", backupServer.isStarted());
       backupConfig.setClusterPassword(CLUSTER_PASSWORD);
       backupServer.start();


Mime
View raw message