[jboss-cvs] JBossAS SVN: r83187 - in projects/ejb3/trunk/testsuite: src/test/java/org/jboss/ejb3/test and 3 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Jan 21 20:29:32 EST 2009
Author: ALRubinger
Date: 2009-01-21 20:29:32 -0500 (Wed, 21 Jan 2009)
New Revision: 83187
Added:
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleBean.java
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleManagement.java
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveBean.java
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.java
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/unit/
projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/unit/ResourceInjectionIntoPrimitivesTestCase.java
Modified:
projects/ejb3/trunk/testsuite/build-test.xml
projects/ejb3/trunk/testsuite/src/test/resources/known-issues.xml
Log:
[EJBTHREE-1647] Add (failing) Integration Test
Modified: projects/ejb3/trunk/testsuite/build-test.xml
===================================================================
--- projects/ejb3/trunk/testsuite/build-test.xml 2009-01-22 01:24:11 UTC (rev 83186)
+++ projects/ejb3/trunk/testsuite/build-test.xml 2009-01-22 01:29:32 UTC (rev 83187)
@@ -2420,6 +2420,10 @@
<build-simple-jar name="ejbthree1624"/>
</target>
+ <target name="ejbthree1647">
+ <build-simple-jar name="ejbthree1647"/>
+ </target>
+
<target name="jbas4489"
description="Builds a simple jar files."
>
@@ -4233,7 +4237,7 @@
ejbthree1066, ejbthree1071, ejbthree1075, ejbthree1082, ejbthree1090, ejbthree1092, ejbthree1116, ejbthree1119, ejbthree1122, ejbthree1123, ejbthree1127,
ejbthree1130,
ejbthree1146, ejbthree1148, ejbthree1154, ejbthree1157, ejbthree1222, ejbthree1271, ejbthree1339,
- ejbthree1504, ejbthree1530, ejbthree1624,
+ ejbthree1504, ejbthree1530, ejbthree1624, ejbthree1647,
jaxws, jbas4489, epcpropagation, aspectdomain, ejbcontext, schema, mail, scopedclassloader, dependency,
securitydomain, enventry, security5,
jms/managed, naming, bmt, jca/inflowmdb, pool, jms, security, reference21_30, factory, dd/web, txexceptions,
@@ -5045,6 +5049,9 @@
<antcall target="test" inheritRefs="true">
<param name="test" value="ejbthree1624"/>
</antcall>
+ <antcall target="test" inheritRefs="true">
+ <param name="test" value="ejbthree1647"/>
+ </antcall>
<antcall target="test" inheritRefs="true">
<param name="test" value="statelesscreation"/>
</antcall>
Added: projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleBean.java
===================================================================
--- projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleBean.java (rev 0)
+++ projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleBean.java 2009-01-22 01:29:32 UTC (rev 83187)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.ejbthree1647;
+
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+
+import org.jboss.ejb3.annotation.Management;
+import org.jboss.ejb3.annotation.Service;
+import org.jboss.naming.Util;
+
+/**
+ * ResourceInjectionLifecycleBean
+ *
+ * @author <a href="mailto:andrew.rubinger at jboss.org">ALR</a>
+ * @version $Revision: $
+ */
+ at Service(objectName = ResourceInjectionLifecycleManagement.OBJECT_NAME)
+ at Management(ResourceInjectionLifecycleManagement.class)
+public class ResourceInjectionLifecycleBean implements ResourceInjectionLifecycleManagement
+{
+ // --------------------------------------------------------------------------------||
+ // Instance Members ---------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /*
+ * Get global JNDI Naming Context
+ */
+ private static Context context;
+ static
+ {
+ try
+ {
+ context = new InitialContext();
+ }
+ catch (NamingException e)
+ {
+ throw new RuntimeException("Could not get naming context", e);
+ }
+ }
+
+ // --------------------------------------------------------------------------------||
+ // Required Implementations -------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /**
+ * Binds all requisite values into JNDI
+ */
+ public void start() throws Exception
+ {
+ // String
+ Util.rebind(context, ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_STRING,
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.VALUE_STRING);
+
+ // int
+ Util.rebind(context, ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INT,
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.VALUE_INT);
+
+ // Integer
+ Util.rebind(context, ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INTEGER,
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.VALUE_INTEGER);
+
+ }
+
+ /**
+ * Cleans up the values bound into JNDI
+ */
+ public void stop()
+ {
+ try
+ {
+ // String
+ Util.unbind(context, ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_STRING);
+
+ // int
+ Util.unbind(context, ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INT);
+
+ // Integer
+ Util.unbind(context, ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INTEGER);
+ }
+ catch (NamingException ne)
+ {
+ throw new RuntimeException(ne);
+ }
+ }
+}
Added: projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleManagement.java
===================================================================
--- projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleManagement.java (rev 0)
+++ projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionLifecycleManagement.java 2009-01-22 01:29:32 UTC (rev 83187)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.ejbthree1647;
+
+/**
+ * ResourceInjectionLifecycleManagement
+ *
+ * @Service MBean interface for lifecycle start/stop
+ *
+ * @author <a href="mailto:andrew.rubinger at jboss.org">ALR</a>
+ * @version $Revision: $
+ */
+public interface ResourceInjectionLifecycleManagement
+{
+ // --------------------------------------------------------------------------------||
+ // Constants ----------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ String OBJECT_NAME = "org.jboss.ejb3:Service=ResourceInjectionLifecycle";
+
+ // --------------------------------------------------------------------------------||
+ // Contracts ----------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /*
+ * Define lifecycle methods
+ */
+
+ void start() throws Exception;
+
+ void stop();
+}
Added: projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveBean.java
===================================================================
--- projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveBean.java (rev 0)
+++ projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveBean.java 2009-01-22 01:29:32 UTC (rev 83187)
@@ -0,0 +1,86 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.ejbthree1647;
+
+import javax.annotation.Resource;
+import javax.ejb.Remote;
+
+import org.jboss.ejb3.annotation.Depends;
+import org.jboss.ejb3.annotation.Service;
+
+/**
+ * ResourceInjectionUsingMappedNameIntoPrimitiveBean
+ *
+ * @author <a href="mailto:andrew.rubinger at jboss.org">ALR</a>
+ * @version $Revision: $
+ */
+ at Service
+ at Remote(ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.class)
+ at Depends(ResourceInjectionLifecycleManagement.OBJECT_NAME)
+// So JNDI entries are bound first
+public class ResourceInjectionUsingMappedNameIntoPrimitiveBean
+ implements
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness
+{
+
+ // --------------------------------------------------------------------------------||
+ // Instance Members ---------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ @Resource(mappedName = ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_STRING)
+ private String stringValue;
+
+ @Resource(mappedName = ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INT)
+ private int intValue;
+
+ @Resource(mappedName = ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INTEGER)
+ private Integer integerValue;
+
+ // --------------------------------------------------------------------------------||
+ // Required Implementations -------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /* (non-Javadoc)
+ * @see org.jboss.ejb3.test.ejbthree1647.ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness#getIntValue()
+ */
+ public int getIntValue()
+ {
+ return intValue;
+ }
+
+ /* (non-Javadoc)
+ * @see org.jboss.ejb3.test.ejbthree1647.ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness#getIntegerValue()
+ */
+ public Integer getIntegerValue()
+ {
+ return integerValue;
+ }
+
+ /* (non-Javadoc)
+ * @see org.jboss.ejb3.test.ejbthree1647.ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness#getStringValue()
+ */
+ public String getStringValue()
+ {
+ return stringValue;
+ }
+
+}
Added: projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.java
===================================================================
--- projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.java (rev 0)
+++ projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.java 2009-01-22 01:29:32 UTC (rev 83187)
@@ -0,0 +1,90 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.ejbthree1647;
+
+/**
+ * ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness
+ *
+ * A remote business interface for an EJB which will inject
+ * into a primitive/Wrapper/String type using @Resource.mappedName
+ *
+ * EJBTHREE-1647
+ *
+ * @author <a href="mailto:andrew.rubinger at jboss.org">ALR</a>
+ * @version $Revision: $
+ */
+public interface ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness
+{
+ // --------------------------------------------------------------------------------||
+ // Constants ----------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /*
+ * The following defines JNDI locations
+ */
+
+ String JNDI_LOCATION_PREFIX = "EJBTHREE1647/";
+
+ String JNDI_LOCATION_STRING = JNDI_LOCATION_PREFIX + "String";
+
+ String JNDI_LOCATION_INT = JNDI_LOCATION_PREFIX + "int";
+
+ String JNDI_LOCATION_INTEGER = JNDI_LOCATION_PREFIX + "Integer";
+
+ /*
+ * The following will be placed into JNDI
+ * at their corresponding location.
+ *
+ * All are String values because this is how metadata
+ * env-refs are stored
+ */
+
+ String VALUE_STRING = "A test String value";
+
+ String VALUE_INT = new Integer(8453459).toString();
+
+ String VALUE_INTEGER = VALUE_INT;
+
+ // --------------------------------------------------------------------------------||
+ // Contracts ----------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /**
+ * Obtains the injected String value
+ *
+ * @return
+ */
+ String getStringValue();
+
+ /**
+ * Obtains the injected int value
+ *
+ * @return
+ */
+ int getIntValue();
+
+ /**
+ * Obtains the injected Integer value
+ * @return
+ */
+ Integer getIntegerValue();
+}
Added: projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/unit/ResourceInjectionIntoPrimitivesTestCase.java
===================================================================
--- projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/unit/ResourceInjectionIntoPrimitivesTestCase.java (rev 0)
+++ projects/ejb3/trunk/testsuite/src/test/java/org/jboss/ejb3/test/ejbthree1647/unit/ResourceInjectionIntoPrimitivesTestCase.java 2009-01-22 01:29:32 UTC (rev 83187)
@@ -0,0 +1,167 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.ejbthree1647.unit;
+
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+
+import junit.framework.Test;
+import junit.framework.TestCase;
+
+import org.jboss.ejb3.test.ejbthree1647.ResourceInjectionUsingMappedNameIntoPrimitiveBean;
+import org.jboss.ejb3.test.ejbthree1647.ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness;
+import org.jboss.test.JBossTestCase;
+
+/**
+ * ResourceInjectionIntoPrimitivesTestCase
+ *
+ * Test Cases to ensure @Resource.mappedName Injection into primitive/wrapper/String
+ * targets succeeds
+ *
+ * EJBTHREE-1647
+ *
+ * @author <a href="mailto:andrew.rubinger at jboss.org">ALR</a>
+ * @version $Revision: $
+ */
+public class ResourceInjectionIntoPrimitivesTestCase extends JBossTestCase
+{
+
+ // --------------------------------------------------------------------------------||
+ // Class Members ------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /**
+ * The hook into the remote container
+ */
+ private static ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness bean;
+
+ // --------------------------------------------------------------------------------||
+ // Constructor --------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ public ResourceInjectionIntoPrimitivesTestCase(String name)
+ {
+ super(name);
+ }
+
+ // --------------------------------------------------------------------------------||
+ // Suite --------------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ public static Test suite() throws Exception
+ {
+ /*
+ * Get the deploy setup
+ */
+ return getDeploySetup(ResourceInjectionIntoPrimitivesTestCase.class, "ejbthree1647.jar");
+ }
+
+ // --------------------------------------------------------------------------------||
+ // Tests --------------------------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /**
+ * Ensures that @Resource.mappedName injection into a String
+ * target succeeds as expected
+ */
+ public void testStringInjectionUsingResourceMappedName()
+ {
+ // Get the bean
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness bean = getBean();
+
+ // Get the value
+ String value = bean.getStringValue();
+
+ // Ensure expected
+ TestCase.assertEquals("String injection not as expected",
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_STRING, value);
+ }
+
+ /**
+ * Ensures that @Resource.mappedName injection into an int
+ * target succeeds as expected
+ */
+ public void testIntInjectionUsingResourceMappedName()
+ {
+ // Get the bean
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness bean = getBean();
+
+ // Get the value
+ int value = bean.getIntValue();
+
+ // Ensure expected
+ TestCase.assertEquals("int injection not as expected",
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INT, value);
+ }
+
+ /**
+ * Ensures that @Resource.mappedName injection into an Integer
+ * target succeeds as expected
+ */
+ public void testIntegerInjectionUsingResourceMappedName()
+ {
+ // Get the bean
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness bean = getBean();
+
+ // Get the value
+ Integer value = bean.getIntegerValue();
+
+ // Ensure expected
+ TestCase.assertEquals("Integer injection not as expected",
+ ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness.JNDI_LOCATION_INTEGER, value);
+ }
+
+ // --------------------------------------------------------------------------------||
+ // Internal Helper Methods --------------------------------------------------------||
+ // --------------------------------------------------------------------------------||
+
+ /**
+ * Returns the access bean, obtaining from JNDI if necessary
+ */
+ private static synchronized ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness getBean()
+ {
+ // If not yet obtained
+ if (bean == null)
+ {
+ // Define JNDI Name
+ String jndiName = ResourceInjectionUsingMappedNameIntoPrimitiveBean.class.getSimpleName() + "/remote";
+
+ try
+ {
+ // Get the naming context
+ Context context = new InitialContext();
+
+ // Get the bean
+ bean = (ResourceInjectionUsingMappedNameIntoPrimitiveRemoteBusiness) context.lookup(jndiName);
+ }
+ catch (NamingException ne)
+ {
+ TestCase.fail("Could not get test bean from JNDI at " + jndiName);
+ }
+ }
+
+ // Return
+ return bean;
+ }
+
+}
Modified: projects/ejb3/trunk/testsuite/src/test/resources/known-issues.xml
===================================================================
--- projects/ejb3/trunk/testsuite/src/test/resources/known-issues.xml 2009-01-22 01:24:11 UTC (rev 83186)
+++ projects/ejb3/trunk/testsuite/src/test/resources/known-issues.xml 2009-01-22 01:29:32 UTC (rev 83187)
@@ -44,5 +44,9 @@
<entry key="org.jboss.ejb3.test.ejbthree1023.unit.DefaultLocalInterfaceWovenBeanTestCase.testDefaultLocalInterfaceWovenBean">show</entry>
<!-- JBMETA-157 -->
<entry key="org.jboss.ejb3.test.naming.unit.NamingTestCase.testJndiOverride">show</entry>
-
+ <!-- EJBTHREE-1647 -->
+ <entry key="org.jboss.ejb3.test.ejbthree1647.unit.ResourceInjectionIntoPrimitivesTestCase.testStringInjectionUsingResourceMappedName">show</entry>
+ <entry key="org.jboss.ejb3.test.ejbthree1647.unit.ResourceInjectionIntoPrimitivesTestCase.testIntInjectionUsingResourceMappedName">show</entry>
+ <entry key="org.jboss.ejb3.test.ejbthree1647.unit.ResourceInjectionIntoPrimitivesTestCase.testIntegerInjectionUsingResourceMappedName">show</entry>
+
</properties>
More information about the jboss-cvs-commits
mailing list