activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hadr...@apache.org
Subject [22/29] git commit: Converted to JUnit4 because of CI hangs, see AMQ-5021
Date Thu, 20 Mar 2014 17:44:33 GMT
Converted to JUnit4 because of CI hangs, see AMQ-5021


Project: http://git-wip-us.apache.org/repos/asf/activemq/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/09f60358
Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/09f60358
Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/09f60358

Branch: refs/heads/activemq-5.9
Commit: 09f6035895a9fbce10b6b5e6b35312d098f602c9
Parents: 19d0909
Author: Kevin Earls <kevin@kevinearls.com>
Authored: Tue Feb 4 11:10:52 2014 +0100
Committer: Hadrian Zbarcea <hadrian@apache.org>
Committed: Thu Mar 20 13:14:53 2014 -0400

----------------------------------------------------------------------
 .../activemq/bugs/MemoryUsageBlockResumeTest.java       | 12 ++++++++++++
 1 file changed, 12 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/09f60358/activemq-unit-tests/src/test/java/org/apache/activemq/bugs/MemoryUsageBlockResumeTest.java
----------------------------------------------------------------------
diff --git a/activemq-unit-tests/src/test/java/org/apache/activemq/bugs/MemoryUsageBlockResumeTest.java
b/activemq-unit-tests/src/test/java/org/apache/activemq/bugs/MemoryUsageBlockResumeTest.java
index 208ac8c..e8d5371 100644
--- a/activemq-unit-tests/src/test/java/org/apache/activemq/bugs/MemoryUsageBlockResumeTest.java
+++ b/activemq-unit-tests/src/test/java/org/apache/activemq/bugs/MemoryUsageBlockResumeTest.java
@@ -36,9 +36,18 @@ import org.apache.activemq.broker.region.policy.PolicyEntry;
 import org.apache.activemq.broker.region.policy.PolicyMap;
 import org.apache.activemq.command.ActiveMQQueue;
 import org.apache.activemq.util.Wait;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.runners.BlockJUnit4ClassRunner;
+import org.junit.runner.RunWith;
+import org.junit.Test;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import static org.junit.Assert.*;
+
+
+@RunWith(BlockJUnit4ClassRunner.class)
 public class MemoryUsageBlockResumeTest extends TestSupport implements Thread.UncaughtExceptionHandler
{
 
     public int deliveryMode = DeliveryMode.PERSISTENT;
@@ -59,6 +68,7 @@ public class MemoryUsageBlockResumeTest extends TestSupport implements Thread.Un
     private String connectionUri;
     private final Vector<Throwable> exceptions = new Vector<Throwable>();
 
+    @Test(timeout = 60 * 1000)
     public void testBlockByOtherResumeNoException() throws Exception {
 
         ActiveMQConnectionFactory factory = new ActiveMQConnectionFactory(connectionUri);
@@ -172,6 +182,7 @@ public class MemoryUsageBlockResumeTest extends TestSupport implements
Thread.Un
     }
 
     @Override
+    @Before
     public void setUp() throws Exception {
 
         Thread.setDefaultUncaughtExceptionHandler(this);
@@ -198,6 +209,7 @@ public class MemoryUsageBlockResumeTest extends TestSupport implements
Thread.Un
     }
 
     @Override
+    @After
     public void tearDown() throws Exception {
         if (broker != null) {
             broker.stop();


Mime
View raw message