activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gtu...@apache.org
Subject svn commit: r1350572 - /activemq/trunk/activemq-pool/src/test/java/org/apache/activemq/pool/PooledConnectionTest.java
Date Fri, 15 Jun 2012 11:03:53 GMT
Author: gtully
Date: Fri Jun 15 11:03:53 2012
New Revision: 1350572

URL: http://svn.apache.org/viewvc?rev=1350572&view=rev
Log:
ensure speedy stop of broker on connection close

Modified:
    activemq/trunk/activemq-pool/src/test/java/org/apache/activemq/pool/PooledConnectionTest.java

Modified: activemq/trunk/activemq-pool/src/test/java/org/apache/activemq/pool/PooledConnectionTest.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-pool/src/test/java/org/apache/activemq/pool/PooledConnectionTest.java?rev=1350572&r1=1350571&r2=1350572&view=diff
==============================================================================
--- activemq/trunk/activemq-pool/src/test/java/org/apache/activemq/pool/PooledConnectionTest.java
(original)
+++ activemq/trunk/activemq-pool/src/test/java/org/apache/activemq/pool/PooledConnectionTest.java
Fri Jun 15 11:03:53 2012
@@ -84,7 +84,9 @@ public class PooledConnectionTest extend
 			Assert.fail("calling ActiveMQConnection.setClientID() twice with different clientID must
raise an IllegalStateException"); 
 		} catch (IllegalStateException ise) {
 			log.debug("Correctly received " + ise);
-		}
+        } finally {
+            conn.close();
+        }
 		
 		// 3rd test: try to call setClientID() after start()
 		// should result in an exception
@@ -96,7 +98,9 @@ public class PooledConnectionTest extend
 		Assert.fail("Calling setClientID() after start() mut raise a JMSException.");
 		} catch (IllegalStateException ise) {
 			log.debug("Correctly received " + ise);
-		}
+        } finally {
+            conn.close();
+        }
 		
 		log.debug("Test finished.");
 	}



Mime
View raw message