[arquillian-issues] [JBoss JIRA] Created: (ARQ-445) Error in docs: Testing JPA and SHRINKWRAP-266
Alberto Gallardo (JIRA)
jira-events at lists.jboss.org
Tue May 17 05:48:00 EDT 2011
Error in docs: Testing JPA and SHRINKWRAP-266
---------------------------------------------
Key: ARQ-445
URL: https://issues.jboss.org/browse/ARQ-445
Project: Arquillian
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Documentation
Affects Versions: 1.0.0.Alpha5
Reporter: Alberto Gallardo
The example in [Reference Guide - 2.3. Testing JPA|http://docs.jboss.org/arquillian/reference/latest/en-US/html_single/#examples.jpa] does not work due to [ShrinkWrap issue 266|https://issues.jboss.org/browse/SHRINKWRAP-266].
The example results in an EJBException:
{code}
javax.ejb.EJBException
at com.sun.ejb.containers.BaseContainer.processSystemException(BaseContainer.java:5194)
[...]
Caused by: java.lang.IllegalStateException: Unable to retrieve EntityManagerFactory for unitName [...]
at com.sun.enterprise.container.common.impl.EntityManagerWrapper.init(EntityManagerWrapper.java:132)
[...]
{code}
There is a work around though:
Add the persistence unit manually in its right location:
{code}
war.addAsWebInfResource("test-persistence.xml", "classes/META-INF/persistence.xml");
{code}
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the arquillian-issues
mailing list