@Before public void setUp() throws Exception { ds = setupPoolingDataSource(); logger.debug("Data source configured with unique id {}", ds.getUniqueName()); emf = Persistence.createEntityManagerFactory(PERSISTENCE_UNIT_NAME); cleanupSingletonSessionId(); }
@Before public void setUp() throws Exception { if (setupDataSource) { ds = setupPoolingDataSource(); logger.debug("Data source configured with unique id {}", ds.getUniqueName()); emf = Persistence.createEntityManagerFactory(persistenceUnitName); } cleanupSingletonSessionId(); }