JMSQueueControl queueControl = createManagementControl();
Assert.assertEquals(2, queueControl.getMessageCount());
// moved all messages to otherQueue
int movedMessagesCount = queueControl.moveMessages(null, otherQueueName);
Assert.assertEquals(2, movedMessagesCount);
Assert.assertEquals(0, queueControl.getMessageCount());
// check there is no message to consume from queue
JMSUtil.consumeMessages(0, queue);