git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@900020 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Timothy A. Bish 2010-01-16 20:27:33 +00:00
parent 1d166a7396
commit 6ea3a22bee
1 changed files with 19 additions and 17 deletions

View File

@ -60,7 +60,7 @@ public class PurgeTest extends EmbeddedBrokerTestSupport {
} }
public static Test suite() { public static Test suite() {
return suite(PurgeTest.class); return suite(PurgeTest.class);
} }
public void testPurge() throws Exception { public void testPurge() throws Exception {
@ -103,10 +103,12 @@ public class PurgeTest extends EmbeddedBrokerTestSupport {
count = proxy.getQueueSize(); count = proxy.getQueueSize();
assertEquals("Queue size", count, 0); assertEquals("Queue size", count, 0);
assertEquals("Browse size", proxy.browseMessages().size(), 0); assertEquals("Browse size", proxy.browseMessages().size(), 0);
producer.close();
} }
public void initCombosForTestDelete() { public void initCombosForTestDelete() {
addCombinationValues("persistenceAdapter", new Object[] {new MemoryPersistenceAdapter(), new AMQPersistenceAdapter(), new JDBCPersistenceAdapter()}); addCombinationValues("persistenceAdapter", new Object[] {new MemoryPersistenceAdapter(), new AMQPersistenceAdapter(), new JDBCPersistenceAdapter()});
} }
public void testDelete() throws Exception { public void testDelete() throws Exception {
@ -160,7 +162,7 @@ public class PurgeTest extends EmbeddedBrokerTestSupport {
} }
private void sendMessages(Session session, int count) throws Exception { private void sendMessages(Session session, int count) throws Exception {
MessageProducer producer = session.createProducer(destination); MessageProducer producer = session.createProducer(destination);
for (int i = 0; i < messageCount; i++) { for (int i = 0; i < messageCount; i++) {
Message message = session.createTextMessage("Message: " + i); Message message = session.createTextMessage("Message: " + i);
producer.send(message); producer.send(message);