diff options
author | Alex Rudyy <orudyy@apache.org> | 2014-07-30 10:06:48 +0000 |
---|---|---|
committer | Alex Rudyy <orudyy@apache.org> | 2014-07-30 10:06:48 +0000 |
commit | 5b965c1bd8161c143f500f8f1f30162728b29baa (patch) | |
tree | 59709943e391efc152023c33c64a83aa66e92906 | |
parent | e14d5ac65ab85136991aedb1802e5b507617c2f1 (diff) | |
download | qpid-python-5b965c1bd8161c143f500f8f1f30162728b29baa.tar.gz |
QPID-5943: Strengthen BDB HA operational logging tests
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1614601 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | qpid/java/bdbstore/src/test/java/org/apache/qpid/server/virtualhostnode/berkeleydb/BDBHAVirtualHostNodeOperationalLoggingTest.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/virtualhostnode/berkeleydb/BDBHAVirtualHostNodeOperationalLoggingTest.java b/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/virtualhostnode/berkeleydb/BDBHAVirtualHostNodeOperationalLoggingTest.java index 9090435e73..665a778dd8 100644 --- a/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/virtualhostnode/berkeleydb/BDBHAVirtualHostNodeOperationalLoggingTest.java +++ b/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/virtualhostnode/berkeleydb/BDBHAVirtualHostNodeOperationalLoggingTest.java @@ -180,6 +180,9 @@ public class BDBHAVirtualHostNodeOperationalLoggingTest extends QpidTestCase node1.setAttributes(Collections.<String, Object>singletonMap(BDBHAVirtualHostNode.PRIORITY, 10)); + // make sure that task executor thread finishes all scheduled tasks + node1.stop(); + String expectedMessage = HighAvailabilityMessages.PRIORITY_CHANGED(node1.getName(), node1.getGroupName(), "10").toString(); verify(_eventLogger).message(argThat(new LogSubjectMatcher(node1.getVirtualHostNodeLogSubject())), argThat(new LogMessageMatcher(expectedMessage, HighAvailabilityMessages.PRIORITY_CHANGED_LOG_HIERARCHY))); @@ -200,6 +203,9 @@ public class BDBHAVirtualHostNodeOperationalLoggingTest extends QpidTestCase node1.setAttributes(Collections.<String, Object>singletonMap(BDBHAVirtualHostNode.QUORUM_OVERRIDE, 1)); + // make sure that task executor thread finishes all scheduled tasks + node1.stop(); + String expectedMessage = HighAvailabilityMessages.QUORUM_OVERRIDE_CHANGED(node1.getName(), node1.getGroupName(), "1").toString(); verify(_eventLogger).message(argThat(new LogSubjectMatcher(node1.getVirtualHostNodeLogSubject())), argThat(new LogMessageMatcher(expectedMessage, HighAvailabilityMessages.QUORUM_OVERRIDE_CHANGED_LOG_HIERARCHY))); @@ -220,6 +226,9 @@ public class BDBHAVirtualHostNodeOperationalLoggingTest extends QpidTestCase node1.setAttributes(Collections.<String, Object>singletonMap(BDBHAVirtualHostNode.DESIGNATED_PRIMARY, true)); + // make sure that task executor thread finishes all scheduled tasks + node1.stop(); + String expectedMessage = HighAvailabilityMessages.DESIGNATED_PRIMARY_CHANGED(node1.getName(), node1.getGroupName(), "true").toString(); verify(_eventLogger).message(argThat(new LogSubjectMatcher(node1.getVirtualHostNodeLogSubject())), argThat(new LogMessageMatcher(expectedMessage, HighAvailabilityMessages.DESIGNATED_PRIMARY_CHANGED_LOG_HIERARCHY))); |