Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit e76a3326 authored by Joze RIHTARSIC's avatar Joze RIHTARSIC
Browse files

enable two datasources for test - old configured by maven and new h2 for unit testing

parent 68dbc253
No related branches found
No related tags found
No related merge requests found
......@@ -58,6 +58,8 @@ public class SmpServicesTestConfig {
driverManagerDataSource.setUsername(username);
driverManagerDataSource.setPassword(password);
return driverManagerDataSource;
}
......@@ -65,6 +67,9 @@ public class SmpServicesTestConfig {
public LocalContainerEntityManagerFactoryBean smpEntityManagerFactory() {
Properties prop = new Properties();
prop.setProperty("org.hibernate.envers.store_data_at_delete", "true");
// test database
prop.setProperty("hibernate.dialect","org.hibernate.dialect.OracleDialect");
LocalContainerEntityManagerFactoryBean lef = new LocalContainerEntityManagerFactoryBean();
lef.setDataSource(smpDataSource());
lef.setJpaVendorAdapter(new HibernateJpaVendorAdapter());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment