@Target(value={TYPE,METHOD,FIELD}) @Retention(value=RUNTIME) public @interface JpaEntityManagerFactory
EntityManagerFactory configuration parameters.
EntityManagerFactory
or a method that takes a single parameter of type EnitityManagerFactory, the EntityManagerFactory
for this test object is injected into this field or method.
org.springframework.orm.jpa.AbstractEntityManagerFactoryBean
parameter, this method becomes a custom configuration method for this EntityManagerFactory. This method
will be invoked when creating a new EntityManagerFactory, after having loaded all other configuration
on this factory bean.
EntityManagerFactory will connect to the unitils configured test datasource, and
will join in unitils test-bound transactions.| Modifier and Type | Optional Element and Description |
|---|---|
String |
configFile
The persistence xml file that has to be loaded for configuring the EntityManagerFactory.
|
String |
databaseName |
String |
persistenceUnit
The name of the persistence unit, as defined in the persistence config file
|
public abstract String persistenceUnit
public abstract String configFile
public abstract String databaseName
Copyright © 2016. All Rights Reserved.