[jboss-cvs] JBossAS SVN: r60928 - branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/partition/test.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Mon Feb 26 22:53:59 EST 2007


Author: bstansberry at jboss.com
Date: 2007-02-26 22:53:59 -0500 (Mon, 26 Feb 2007)
New Revision: 60928

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/partition/test/PartitionRestartUnitTestCase.java
Log:
Don't use HA-JNDI discovery; it's not needed

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/partition/test/PartitionRestartUnitTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/partition/test/PartitionRestartUnitTestCase.java	2007-02-27 03:47:55 UTC (rev 60927)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/partition/test/PartitionRestartUnitTestCase.java	2007-02-27 03:53:59 UTC (rev 60928)
@@ -21,6 +21,8 @@
  */
 package org.jboss.test.cluster.partition.test;
 
+import java.util.Properties;
+
 import javax.management.ObjectName;
 import javax.naming.Context;
 import javax.naming.InitialContext;
@@ -64,7 +66,12 @@
       
       RMIAdaptor[] adaptors = this.getAdaptors(); 
       
-      Context ctx = new InitialContext();
+      String[] urls = getNamingURLs();
+      Properties env = new Properties();
+      env.setProperty(Context.INITIAL_CONTEXT_FACTORY,
+         "org.jnp.interfaces.NamingContextFactory");
+      env.setProperty(Context.PROVIDER_URL, urls[0]);
+      Context ctx = new InitialContext(env);
       getLog().debug("OK");
       
       getLog().debug("");
@@ -124,6 +131,10 @@
       Object[] params = new Object[0];
       String[] types = new String[0];
       adaptor.invoke(partition, "stop", params, types);
+      
+      // Let it stabilize a bit
+      sleep(250);
+      
       adaptor.invoke(partition, "start", params, types);
    }
 




More information about the jboss-cvs-commits mailing list