[jboss-cvs] JBossAS SVN: r61778 - branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Mar 28 09:02:58 EDT 2007


Author: dimitris at jboss.org
Date: 2007-03-28 09:02:58 -0400 (Wed, 28 Mar 2007)
New Revision: 61778

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestCase.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestRunner.java
Log:
JBAS-4144, remove remaining uses of the legacy ejbunit class (i.e. cmp2 tests)

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestCase.java	2007-03-28 13:00:01 UTC (rev 61777)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestCase.java	2007-03-28 13:02:58 UTC (rev 61778)
@@ -21,8 +21,8 @@
  */
 package org.jboss.test.util.ejb;
 
+import java.util.Properties;
 
-import java.util.Properties;
 import javax.naming.InitialContext;
 import javax.rmi.PortableRemoteObject;
 
@@ -62,7 +62,8 @@
  * @see junit.framework.TestCase
  *
  * @author <a href="mailto:dain at daingroup.com">Dain Sundstrom</a>
- * @author Scott.Stark at jboss.org
+ * @author <a href="mailto:scott at jboss.org">Scott Stark</a>
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
  * @version $Revision$
  */
 public class EJBTestCase extends TestCase
@@ -209,8 +210,17 @@
    public void setUpEJB(Properties props) throws Exception
    {
       this.props = props;
+
+      // JBAS-4144, hack to allow subclasses that originally
+      // used net.sourceforge.junitejb.EJBTestCase to still work.
+      setUpEJB();
    }
 
+   public void setUpEJB() throws Exception
+   {
+      // empty
+   }
+   
    /** Tears down the ejb test case. This method is called after
     * each test is executed and is run in a private transaction.
     * @param props the properties passed in from the client
@@ -218,8 +228,16 @@
     */
    public void tearDownEJB(Properties props) throws Exception
    {
+      // JBAS-4144, hack to allow subclasses that originally
+      // used net.sourceforge.junitejb.EJBTestCase to still work.
+      tearDownEJB();
    }
 
+   public void tearDownEJB() throws Exception
+   {
+      // empty
+   }
+   
    /**
     * Looks up the ejb test runner home in JNDI (at "ejb/EJBTestRunner")
     * and creates a new runner.

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestRunner.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestRunner.java	2007-03-28 13:00:01 UTC (rev 61777)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/util/ejb/EJBTestRunner.java	2007-03-28 13:02:58 UTC (rev 61778)
@@ -41,9 +41,9 @@
  *       &lt;session&gt;
  *          &lt;description&gt;JUnit Session Bean Test Runner&lt;/description&gt;
  *          &lt;ejb-name&gt;EJBTestRunnerEJB&lt;/ejb-name&gt;
- *          &lt;home&gt;net.sourceforge.junitejb.EJBTestRunnerHome&lt;/home&gt;
- *          &lt;remote&gt;net.sourceforge.junitejb.EJBTestRunner&lt;/remote&gt;
- *          &lt;ejb-class&gt;net.sourceforge.junitejb.EJBTestRunnerBean&lt;/ejb-class&gt;
+ *          &lt;home&gt;org.jboss.test.util.ejb.EJBTestRunnerHome&lt;/home&gt;
+ *          &lt;remote&gt;org.jboss.test.util.ejb.EJBTestRunner&lt;/remote&gt;
+ *          &lt;ejb-class&gt;org.jboss.test.util.ejb.EJBTestRunnerBean&lt;/ejb-class&gt;
  *          &lt;session-type&gt;Stateless&lt;/session-type&gt;
  *          &lt;transaction-type&gt;Bean&lt;/transaction-type&gt;
  *       &lt;/session&gt;




More information about the jboss-cvs-commits mailing list