activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jgo...@apache.org
Subject svn commit: r1325575 - /activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/TempDestinationTest.cs
Date Fri, 13 Apr 2012 00:19:11 GMT
Author: jgomes
Date: Fri Apr 13 00:19:11 2012
New Revision: 1325575

URL: http://svn.apache.org/viewvc?rev=1325575&view=rev
Log:
Delete the test queue before starting the test to avoid any cruft hanging around from previous
test runs.

Modified:
    activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/TempDestinationTest.cs

Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/TempDestinationTest.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/TempDestinationTest.cs?rev=1325575&r1=1325574&r2=1325575&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/TempDestinationTest.cs
(original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/TempDestinationTest.cs
Fri Apr 13 00:19:11 2012
@@ -287,15 +287,12 @@ namespace Apache.NMS.ActiveMQ.Test
 			Connection consumerConnection = GetNewConnection();
 			ISession consumerSession = consumerConnection.CreateSession(AcknowledgementMode.AutoAcknowledge);
 			IDestination consumerDestination = consumerSession.GetQueue(msgQueueName);
+			// Make sure we have a fresh test queue.
+			consumerConnection.DeleteDestination(consumerDestination);
 			IMessageConsumer consumer = consumerSession.CreateConsumer(consumerDestination);
 
 			consumerConnection.Start();
 
-			// Purge the destination before starting.
-			while(consumer.Receive(TimeSpan.FromMilliseconds(3000)) != null)
-			{
-			}
-
 			IMessageConsumer advisoryConsumer = consumerSession.CreateConsumer(AdvisorySupport.TEMP_DESTINATION_COMPOSITE_ADVISORY_TOPIC);
 			advisoryConsumer.Listener += OnAdvisoryMessage;
 



Mime
View raw message