qpid-broker-j git commit: QPID-7811: Improve test to verify that last stored orphaned message is removed

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

qpid-broker-j git commit: QPID-7811: Improve test to verify that last stored orphaned message is removed

orudyy
Repository: qpid-broker-j
Updated Branches:
  refs/heads/master cf1af38c6 -> f03a3c460


QPID-7811: Improve test to verify that last stored orphaned message is removed


Project: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/commit/f03a3c46
Tree: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/tree/f03a3c46
Diff: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/diff/f03a3c46

Branch: refs/heads/master
Commit: f03a3c460b1782688627588fcb646df6a9a537e6
Parents: cf1af38
Author: Alex Rudyy <[hidden email]>
Authored: Fri Jun 9 17:07:11 2017 +0100
Committer: Alex Rudyy <[hidden email]>
Committed: Fri Jun 9 17:07:11 2017 +0100

----------------------------------------------------------------------
 .../virtualhost/AsynchronousMessageStoreRecovererTest.java       | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/f03a3c46/broker-core/src/test/java/org/apache/qpid/server/virtualhost/AsynchronousMessageStoreRecovererTest.java
----------------------------------------------------------------------
diff --git a/broker-core/src/test/java/org/apache/qpid/server/virtualhost/AsynchronousMessageStoreRecovererTest.java b/broker-core/src/test/java/org/apache/qpid/server/virtualhost/AsynchronousMessageStoreRecovererTest.java
index f8a0589..49d6a80 100644
--- a/broker-core/src/test/java/org/apache/qpid/server/virtualhost/AsynchronousMessageStoreRecovererTest.java
+++ b/broker-core/src/test/java/org/apache/qpid/server/virtualhost/AsynchronousMessageStoreRecovererTest.java
@@ -118,6 +118,9 @@ public class AsynchronousMessageStoreRecovererTest extends QpidTestCase
         final List<StoredMessage<?>> testMessages = new ArrayList<>();
         StoredMessage<?> storedMessage = createTestMessage(1L);
         testMessages.add(storedMessage);
+        StoredMessage<?> orphanedMessage = createTestMessage(2L);
+        testMessages.add(orphanedMessage);
+
         StoredMessage newMessage = createTestMessage(4L);
         testMessages.add(newMessage);
 
@@ -133,6 +136,7 @@ public class AsynchronousMessageStoreRecovererTest extends QpidTestCase
         ListenableFuture<Void> result = recoverer.recover(_virtualHost);
         assertNull(result.get());
 
+        verify(orphanedMessage, times(1)).remove();
         verify(newMessage, times(0)).remove();
         verify(queue).recover(argThat(new ArgumentMatcher<ServerMessage>()
         {


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Loading...