Uploaded image for project: 'Application Server 3  4  5 and 6'
  1. Application Server 3 4 5 and 6
  2. JBAS-3543

org.jboss.test.entity.test.EntityUnitTestCase fails because "test" is not bound

    XMLWordPrintable

Details

    • Bug
    • Resolution: Cannot Reproduce
    • Major
    • None
    • JBossAS-5.0.0.Beta1
    • Test Suite
    • None

    Description

      org.jboss.test.entity.test.EntityUnitTestCase because "test" is not bound at the beginning of the test nor at startup of the server.
      FIX:
      Create directory META-INF in testsuite/src/resources/entity/entity
      In META-INF create two xml files:

      ejb-jar.xml
      **********************************************
      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">

      <ejb-jar >

      <description><![CDATA[No Description.]]></description>
      <display-name>Generated by XDoclet</display-name>

      <enterprise-beans>

      <!-- Session Beans -->
      <!--
      To add session beans that you have deployment descriptor info for, add
      a file to your XDoclet merge directory called session-beans.xml that contains
      the <session></session> markup for those beans.
      -->

      <!-- Entity Beans -->
      <entity >
      <description><![CDATA[An entity.]]></description>

      <ejb-name>TestEntity</ejb-name>

      <home>org.jboss.test.entity.interfaces.TestEntityHome</home>
      <remote>org.jboss.test.entity.interfaces.TestEntity</remote>
      <local-home>org.jboss.test.entity.interfaces.TestEntityLocalHome</local-home>
      <local>org.jboss.test.entity.interfaces.TestEntityLocal</local>

      <ejb-class>org.jboss.test.entity.beans.TestEntityCMP</ejb-class>
      <persistence-type>Container</persistence-type>
      <prim-key-class>java.lang.String</prim-key-class>
      <reentrant>False</reentrant>
      <cmp-version>2.x</cmp-version>
      <abstract-schema-name>test</abstract-schema-name>
      <cmp-field >
      <description><![CDATA[]]></description>
      <field-name>entityID</field-name>
      </cmp-field>
      <cmp-field >
      <description><![CDATA[]]></description>
      <field-name>value1</field-name>
      </cmp-field>
      <primkey-field>entityID</primkey-field>

      <!-- Write a file named ejb-finders-TestEntityBean.xml if you want to define extra finders. -->
      </entity>

      <!--
      To add entity beans that you have deployment descriptor info for, add
      a file to your XDoclet merge directory called entity-beans.xml that contains
      the <entity></entity> markup for those beans.
      -->

      <!-- Message Driven Beans -->
      <!--
      To add message driven beans that you have deployment descriptor info for, add
      a file to your XDoclet merge directory called message-driven-beans.xml that contains
      the <message-driven></message-driven> markup for those beans.
      -->

      </enterprise-beans>

      <!-- Relationships -->

      <!-- Assembly Descriptor -->
      <assembly-descriptor >
      <!--
      To add additional assembly descriptor info here, add a file to your
      XDoclet merge directory called assembly-descriptor.xml that contains
      the <assembly-descriptor></assembly-descriptor> markup.
      -->

      <!-- finder permissions -->

      <!-- transactions -->
      <container-transaction >
      <method >
      <ejb-name>TestEntity</ejb-name>
      <method-name>*</method-name>
      </method>
      <trans-attribute>Required</trans-attribute>
      </container-transaction>

      <!-- finder transactions -->
      </assembly-descriptor>

      </ejb-jar>
      *************************************
      *************************************
      *************************************
      jboss.xml
      *************************************
      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 3.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_3_0.dtd">

      <jboss>

      <enterprise-beans>

      <!--
      To add beans that you have deployment descriptor info for, add
      a file to your XDoclet merge directory called jboss-beans.xml that contains
      the <session></session>, <entity></entity> and <message-driven></message-driven>
      markup for those beans.
      -->

      <entity>
      <ejb-name>TestEntity</ejb-name>
      <jndi-name>test/entity/TestEntity</jndi-name>
      <local-jndi-name>test/entity/TestEntityLocal</local-jndi-name>
      <configuration-name>TestEntity Container Configuration</configuration-name>

      </entity>

      </enterprise-beans>

      <resource-managers>
      </resource-managers>

      <container-configurations>
      <!-- Commit option B CMP Bean -->
      <container-configuration extends="Standard CMP 2.x EntityBean">
      <container-name>TestEntity Container Configuration</container-name>
      <commit-option>B</commit-option>
      </container-configuration>
      </container-configurations>

      </jboss>

      Attachments

        Activity

          People

            Unassigned Unassigned
            jaroslaw.kijanowski Jaroslaw Kijanowski (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: