[jboss-cvs] JBoss Messaging SVN: r2959 - trunk/tests/src/org/jboss/test/messaging/jms/clustering.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Mon Aug 6 12:39:25 EDT 2007


Author: timfox
Date: 2007-08-06 12:39:25 -0400 (Mon, 06 Aug 2007)
New Revision: 2959

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/MergeQueueTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultiThreadFailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultipleFailoverTest.java
Log:
tests speedup


Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/MergeQueueTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/MergeQueueTest.java	2007-08-06 15:43:52 UTC (rev 2958)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/MergeQueueTest.java	2007-08-06 16:39:25 UTC (rev 2959)
@@ -25,7 +25,7 @@
  *
  * $Id$
  */
-public class MergeQueueTest extends ClusteringTestBase
+public class MergeQueueTest extends NewClusteringTestBase
 {
    // Constants ------------------------------------------------------------------------------------
 
@@ -349,6 +349,8 @@
          
          assertNull(tm);
          
+         session0.commit();
+         
       }
       finally
       {
@@ -578,7 +580,9 @@
                   
          tm = (TextMessage)cons0.receive(2000);
          
-         assertNull(tm);         
+         assertNull(tm);    
+         
+         session0.commit();
       }
       finally
       {
@@ -619,24 +623,8 @@
       nodeCount = 2;
 
       super.setUp();
-
-      log.debug("setup done");
    }
 
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-      
-      for (int i = 0; i < nodeCount; i++)
-      {
-         if (ServerManagement.isStarted(i))
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server " + i, i);
-            ServerManagement.stop(i);
-         }
-      }
-   }
-
    // Private --------------------------------------------------------------------------------------
 
    // Inner classes --------------------------------------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultiThreadFailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultiThreadFailoverTest.java	2007-08-06 15:43:52 UTC (rev 2958)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultiThreadFailoverTest.java	2007-08-06 16:39:25 UTC (rev 2959)
@@ -46,7 +46,7 @@
  *
  * $Id$
  */
-public class MultiThreadFailoverTest extends ClusteringTestBase
+public class MultiThreadFailoverTest extends NewClusteringTestBase
 {
 
    // Constants ------------------------------------------------------------------------------------
@@ -255,15 +255,11 @@
       multiThreadFailover(1, 1, false, true);
    }
 
-   // TODO TEST TEMPORARILY COMMENTED OUT.
-   //      MUST BE UNCOMMENTED FOR  1.2.1!
-   //      http://jira.jboss.org/jira/browse/JBMESSAGING-883
+   public void testMultiThreadFailoverSingleThreadTransacted() throws Exception
+   {
+      multiThreadFailover(1, 1, true, true);
+   }
 
-//   public void testMultiThreadFailoverSingleThreadTransacted() throws Exception
-//   {
-//      multiThreadFailover(1, 1, true, true);
-//   }
-
    public void testMultiThreadFailoverSingleThreadNonPersistent() throws Exception
    {
       multiThreadFailover(1, 1, false, false);
@@ -274,15 +270,11 @@
       multiThreadFailover(5, 10, false, true);
    }
 
-   // TODO TEST TEMPORARILY COMMENTED OUT.
-   //      MUST BE UNCOMMENTED FOR  1.2.1!
-   //      See http://jira.jboss.org/jira/browse/JBMESSAGING-883
+   public void testMultiThreadFailoverSeveralThreadsTransacted() throws Exception
+   {
+      multiThreadFailover(5, 10, true, true);
+   }
 
-//   public void testMultiThreadFailoverSeveralThreadsTransacted() throws Exception
-//   {
-//      multiThreadFailover(5, 10, true, true);
-//   }
-
    public void testMultiThreadFailoverNonPersistent() throws Exception
    {
       multiThreadFailover(5, 10, false, false);
@@ -470,25 +462,9 @@
       nodeCount = 3;
 
       super.setUp();
-
-      log.debug("setup done");
    }
 
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-      
-      for (int i = 0; i < nodeCount; i++)
-      {
-         if (ServerManagement.isStarted(i))
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server " + i, i);
-            ServerManagement.stop(i);
-         }
-      }
-   }
 
-
    // Private --------------------------------------------------------------------------------------
 
    // Inner classes --------------------------------------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultipleFailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultipleFailoverTest.java	2007-08-06 15:43:52 UTC (rev 2958)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/MultipleFailoverTest.java	2007-08-06 16:39:25 UTC (rev 2959)
@@ -46,7 +46,7 @@
  *
  * $Id$
  */
-public class MultipleFailoverTest extends ClusteringTestBase
+public class MultipleFailoverTest extends NewClusteringTestBase
 {
    // Constants ------------------------------------------------------------------------------------
 
@@ -72,7 +72,6 @@
 
       try
       {
-
          conn = this.createConnectionOnServer(cf, 1);
          conn.start();
 
@@ -161,6 +160,7 @@
 
          ServerManagement.start(1, "all", false);
          ServerManagement.deployQueue("testDistributedQueue", 1);
+         ServerManagement.deployTopic("testDistributedTopic", 1);
 
          // send/receive message
          prod.send(s.createTextMessage("step7"));
@@ -317,24 +317,8 @@
       nodeCount = 3;
 
       super.setUp();
-
-      log.debug("setup done");
    }
 
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-      
-      for (int i = 0; i < nodeCount; i++)
-      {
-         if (ServerManagement.isStarted(i))
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server " + i, i);
-            ServerManagement.stop(i);
-         }
-      }
-   }
-
    // Private --------------------------------------------------------------------------------------
 
    // Inner classes --------------------------------------------------------------------------------
@@ -409,6 +393,7 @@
             log.info("Starting server 1");
             ServerManagement.start(1, "all", false);
             ServerManagement.deployQueue("testDistributedQueue", 1);
+            ServerManagement.deployTopic("testDistributedTopic", 1);
             
             Thread.sleep(10000);
             




More information about the jboss-cvs-commits mailing list