Package org.apache.openjpa.junit5
Annotation Type OpenJPASupport
-
@Target(TYPE) @Retention(RUNTIME) @ExtendWith(OpenJPAExtension.class) public @interface OpenJPASupport
Enables in place enhancement for entities listed or found by scanning in test classpath. It enables to run tests from the IDE with enhancement. WARNING: if you use that for tests but don't want to enhance your entities, ensure to clean+recompile them after tests otherwise you will have entities depending on OpenJPA at bytecode level.
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description boolean
auto
String[]
entities
Class<?>
logFactory
-
-
-
Element Detail
-
entities
String[] entities
- Returns:
- the list of class names (don't use
MyEntity.class
) to enhance ifauto
is false.
- Default:
- {}
-
-
-
auto
boolean auto
- Returns:
- if true, only directories in the classpath will be browsed to enhance entities,
if false
entities()
will be used.
- Default:
- true
-
-
-
logFactory
Class<?> logFactory
- Returns:
- the log factory to use, if not set slf4j will be tried and if it fails will fallback on the default one.
- Default:
- org.apache.openjpa.lib.log.LogFactory.class
-
-