[jboss-cvs] JBossAS SVN: r63293 - in branches/Branch_4_2/ejb3: src/resources/test and 5 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Fri Jun 1 03:27:07 EDT 2007
Author: wolfc
Date: 2007-06-01 03:27:07 -0400 (Fri, 01 Jun 2007)
New Revision: 63293
Added:
branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/
branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/
branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java
Removed:
branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/
branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/
branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java
Modified:
branches/Branch_4_2/ejb3/build-test.xml
Log:
EJBTHREE-959: merged unit test
Modified: branches/Branch_4_2/ejb3/build-test.xml
===================================================================
--- branches/Branch_4_2/ejb3/build-test.xml 2007-06-01 05:08:31 UTC (rev 63292)
+++ branches/Branch_4_2/ejb3/build-test.xml 2007-06-01 07:27:07 UTC (rev 63293)
@@ -1809,6 +1809,13 @@
</jar>
</target>
+ <target name="ejbthree959"
+ description="Builds simple jar file."
+ depends="compile-classes">
+
+ <build-simple-jar name="ejbthree959"/>
+ </target>
+
<target name="jaxws"
description="Builds a simple jar."
depends="compile-classes">
@@ -3198,6 +3205,7 @@
<target name="jars" depends="entityoptimisticlocking, concurrentnaming, propertyreplacement, persistenceunits, invalidtxmdb, descriptortypo, libdeployment, homeinterface, timestampentity, servicexmbean, arjuna, mdbtransactions, unauthenticatedprincipal, clusteredservice, invoker, classloader,
circulardependency, jsp, timerdependency, servicedependency, servlet, stateless14, webservices, ear, ejbthree440,
ejbthree454, ejbthree653, ejbthree670, ejbthree712, ejbthree724, ejbthree751, ejbthree832, ejbthree921,
+ ejbthree959,
aspectdomain, ejbcontext, schema, mail, scopedclassloader, dependency, jaxws,
pkg, securitydomain, enventry,
jms/managed, naming, bmt, jca/inflowmdb, pool, jms, security, reference21_30, factory, dd/web, txexceptions,
@@ -3721,6 +3729,9 @@
<antcall target="test" inheritRefs="true">
<param name="test" value="ejbthree832"/>
</antcall>
+ <antcall target="test" inheritRefs="true">
+ <param name="test" value="ejbthree959"/>
+ </antcall>
</target>
<target name="entity-tests" depends="init" description="Execute all tests">
Copied: branches/Branch_4_2/ejb3/src/resources/test/ejbthree959 (from rev 62963, trunk/ejb3/src/resources/test/ejbthree959)
Copied: branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF (from rev 62963, trunk/ejb3/src/resources/test/ejbthree959/META-INF)
Deleted: branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml
===================================================================
--- trunk/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml 2007-05-10 09:58:08 UTC (rev 62963)
+++ branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml 2007-06-01 07:27:07 UTC (rev 63293)
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- we're going to force this down the ejb3 deployer -->
-<ejb-jar
- xmlns="http://java.sun.com/xml/ns/javaee"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
- http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
- version="3.0">
- <display-name>ejbthree959</display-name>
- <enterprise-beans>
- <session>
- <ejb-name>MyStateful</ejb-name>
- <home>org.jboss.ejb3.test.ejbthree959.MyStatefulHome</home>
- <remote>org.jboss.ejb3.test.ejbthree959.MyStateful</remote>
- <ejb-class>org.jboss.ejb3.test.ejbthree959.MyStatefulBean</ejb-class>
- <session-type>Stateful</session-type>
- <transaction-type>Container</transaction-type>
- </session>
- </enterprise-beans>
-</ejb-jar>
\ No newline at end of file
Copied: branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml (from rev 62963, trunk/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml)
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml (rev 0)
+++ branches/Branch_4_2/ejb3/src/resources/test/ejbthree959/META-INF/ejb-jar.xml 2007-06-01 07:27:07 UTC (rev 63293)
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- we're going to force this down the ejb3 deployer -->
+<ejb-jar
+ xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
+ version="3.0">
+ <display-name>ejbthree959</display-name>
+ <enterprise-beans>
+ <session>
+ <ejb-name>MyStateful</ejb-name>
+ <home>org.jboss.ejb3.test.ejbthree959.MyStatefulHome</home>
+ <remote>org.jboss.ejb3.test.ejbthree959.MyStateful</remote>
+ <ejb-class>org.jboss.ejb3.test.ejbthree959.MyStatefulBean</ejb-class>
+ <session-type>Stateful</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+ </enterprise-beans>
+</ejb-jar>
\ No newline at end of file
Copied: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959 (from rev 62963, trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959)
Deleted: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java 2007-05-10 09:58:08 UTC (rev 62963)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -1,36 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.ejb3.test.ejbthree959;
-
-import javax.ejb.EJBObject;
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public interface MyStateful extends EJBObject
-{
- String sayHi();
- void setName(String name);
-}
Copied: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java (from rev 62963, trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java)
===================================================================
--- branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java (rev 0)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStateful.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.test.ejbthree959;
+
+import javax.ejb.EJBObject;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface MyStateful extends EJBObject
+{
+ String sayHi();
+ void setName(String name);
+}
Deleted: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java 2007-05-10 09:58:08 UTC (rev 62963)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -1,95 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.ejb3.test.ejbthree959;
-
-import java.rmi.RemoteException;
-
-import javax.ejb.CreateException;
-import javax.ejb.EJBException;
-import javax.ejb.SessionBean;
-import javax.ejb.SessionContext;
-
-/**
- * A 2.1 stateful bean.
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class MyStatefulBean implements SessionBean
-{
- private static final long serialVersionUID = 1L;
-
- @SuppressWarnings("unused")
- private SessionContext ctx;
-
- private String name;
-
- /* plumbing */
-
- public void ejbActivate() throws EJBException, RemoteException
- {
- }
-
- public void ejbPassivate() throws EJBException, RemoteException
- {
- }
-
- public void ejbRemove() throws EJBException, RemoteException
- {
- }
-
- public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
- {
- this.ctx = ctx;
- }
-
- /* home interface */
-
- public void ejbCreate() throws CreateException, RemoteException
- {
- }
-
- public void ejbPostCreate() throws CreateException, RemoteException
- {
- }
-
- public void ejbCreate(String name) throws CreateException, RemoteException
- {
- setName(name);
- }
-
- public void ejbPostCreate(String name) throws CreateException, RemoteException
- {
- }
-
- /* actual stuff */
-
- public String sayHi()
- {
- return "Hi " + name;
- }
-
- public void setName(String name)
- {
- this.name = name;
- }
-}
Copied: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java (from rev 62963, trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java)
===================================================================
--- branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java (rev 0)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulBean.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -0,0 +1,95 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.test.ejbthree959;
+
+import java.rmi.RemoteException;
+
+import javax.ejb.CreateException;
+import javax.ejb.EJBException;
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+
+/**
+ * A 2.1 stateful bean.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class MyStatefulBean implements SessionBean
+{
+ private static final long serialVersionUID = 1L;
+
+ @SuppressWarnings("unused")
+ private SessionContext ctx;
+
+ private String name;
+
+ /* plumbing */
+
+ public void ejbActivate() throws EJBException, RemoteException
+ {
+ }
+
+ public void ejbPassivate() throws EJBException, RemoteException
+ {
+ }
+
+ public void ejbRemove() throws EJBException, RemoteException
+ {
+ }
+
+ public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
+ {
+ this.ctx = ctx;
+ }
+
+ /* home interface */
+
+ public void ejbCreate() throws CreateException, RemoteException
+ {
+ }
+
+ public void ejbPostCreate() throws CreateException, RemoteException
+ {
+ }
+
+ public void ejbCreate(String name) throws CreateException, RemoteException
+ {
+ setName(name);
+ }
+
+ public void ejbPostCreate(String name) throws CreateException, RemoteException
+ {
+ }
+
+ /* actual stuff */
+
+ public String sayHi()
+ {
+ return "Hi " + name;
+ }
+
+ public void setName(String name)
+ {
+ this.name = name;
+ }
+}
Deleted: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java 2007-05-10 09:58:08 UTC (rev 62963)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -1,39 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.ejb3.test.ejbthree959;
-
-import java.rmi.RemoteException;
-
-import javax.ejb.CreateException;
-import javax.ejb.EJBHome;
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public interface MyStatefulHome extends EJBHome
-{
- MyStateful create() throws CreateException, RemoteException;
- MyStateful create(String name) throws CreateException, RemoteException;
-}
Copied: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java (from rev 62963, trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java)
===================================================================
--- branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java (rev 0)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/MyStatefulHome.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.test.ejbthree959;
+
+import java.rmi.RemoteException;
+
+import javax.ejb.CreateException;
+import javax.ejb.EJBHome;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface MyStatefulHome extends EJBHome
+{
+ MyStateful create() throws CreateException, RemoteException;
+ MyStateful create(String name) throws CreateException, RemoteException;
+}
Copied: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit (from rev 62963, trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit)
Deleted: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java 2007-05-10 09:58:08 UTC (rev 62963)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -1,71 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.ejb3.test.ejbthree959.unit;
-
-import javax.rmi.PortableRemoteObject;
-
-import junit.framework.Test;
-
-import org.jboss.ejb3.test.ejbthree959.MyStateful;
-import org.jboss.ejb3.test.ejbthree959.MyStatefulHome;
-import org.jboss.test.JBossTestCase;
-
-
-/**
- * Test if an EJB 2.1 bean is properly deployed.
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class EJB21TestCase extends JBossTestCase
-{
-
- public EJB21TestCase(String name)
- {
- super(name);
- }
-
- public void testCreateNoArgs() throws Exception
- {
- MyStatefulHome home = (MyStatefulHome) PortableRemoteObject.narrow(getInitialContext().lookup("MyStateful/home"), MyStatefulHome.class);
- MyStateful bean = home.create();
- bean.setName("testCreateNoArgs");
- String expected = "Hi testCreateNoArgs";
- String actual = bean.sayHi();
- assertEquals(expected, actual);
- }
-
- public void testCreateWithArgs() throws Exception
- {
- MyStatefulHome home = (MyStatefulHome) PortableRemoteObject.narrow(getInitialContext().lookup("MyStateful/home"), MyStatefulHome.class);
- MyStateful bean = home.create("testCreateWithArgs");
- String expected = "Hi testCreateWithArgs";
- String actual = bean.sayHi();
- assertEquals(expected, actual);
- }
-
- public static Test suite() throws Exception
- {
- return getDeploySetup(EJB21TestCase.class, "ejbthree959.jar");
- }
-
-}
Copied: branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java (from rev 62963, trunk/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java)
===================================================================
--- branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java (rev 0)
+++ branches/Branch_4_2/ejb3/src/test/org/jboss/ejb3/test/ejbthree959/unit/EJB21TestCase.java 2007-06-01 07:27:07 UTC (rev 63293)
@@ -0,0 +1,71 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2007, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.ejb3.test.ejbthree959.unit;
+
+import javax.rmi.PortableRemoteObject;
+
+import junit.framework.Test;
+
+import org.jboss.ejb3.test.ejbthree959.MyStateful;
+import org.jboss.ejb3.test.ejbthree959.MyStatefulHome;
+import org.jboss.test.JBossTestCase;
+
+
+/**
+ * Test if an EJB 2.1 bean is properly deployed.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class EJB21TestCase extends JBossTestCase
+{
+
+ public EJB21TestCase(String name)
+ {
+ super(name);
+ }
+
+ public void testCreateNoArgs() throws Exception
+ {
+ MyStatefulHome home = (MyStatefulHome) PortableRemoteObject.narrow(getInitialContext().lookup("MyStateful/home"), MyStatefulHome.class);
+ MyStateful bean = home.create();
+ bean.setName("testCreateNoArgs");
+ String expected = "Hi testCreateNoArgs";
+ String actual = bean.sayHi();
+ assertEquals(expected, actual);
+ }
+
+ public void testCreateWithArgs() throws Exception
+ {
+ MyStatefulHome home = (MyStatefulHome) PortableRemoteObject.narrow(getInitialContext().lookup("MyStateful/home"), MyStatefulHome.class);
+ MyStateful bean = home.create("testCreateWithArgs");
+ String expected = "Hi testCreateWithArgs";
+ String actual = bean.sayHi();
+ assertEquals(expected, actual);
+ }
+
+ public static Test suite() throws Exception
+ {
+ return getDeploySetup(EJB21TestCase.class, "ejbthree959.jar");
+ }
+
+}
More information about the jboss-cvs-commits
mailing list