Hi
I have a strange problem with OpenJPA and I have had no success
finding a solution on the net (yet).
We have a multi module maven2 project, the subprojects interesting in
this case beeing a data model with annotated classes - "model" and
ejb3 beans accessing the data - "ejb".
I have managed to set up unit tests in the ejb project by making
maven copy the model-jar into the target/test-classes and referencing
it from src/test/resources/META-INF/persistence.xml. This works well.
Since we want to catch the mapping errors etc. with the unit tests in
the model I have been working on setting up OpenJPA for the unit
tests in that project as well. When the unit tests are run they fail
with the following exception from OpenJPA:
<openjpa-1.0.0-r420667:568756 fatal user error>
org.apache.openjpa.persistence.ArgumentException: The type "class
se.databyran.prosang.questionnaire.Questionnaire" has not been enhanced.
I have seen another question about this and tried to set the
"openjpa.RuntimeUnenhancedClasses" property to "warn" but this does
not seem to affect the problem in any way.
The only difference I can se between the successful setup and the
failing one is that the entity classes are packed in a jar in the ejb
project and only as directories in the classpath in the failing one.
Is this a known problem?
Versions:
Java 1.5
Maven 2.0.7
OpenJPA 1.0.0
--
Best regards
Johan Andrén [EMAIL PROTECTED]
Databyrån AB http://www.databyran.se/
Tel: +46(0) 8 50 65 64 00
Fax: +46(0) 8 50 65 64 30
Databyrån AB är certifierat enligt ISO 9001:2000