JPA parameters fix
authorindvdum (gotoindvdum[at]gmail[dot]com)
Sun, 11 Nov 2012 01:24:41 +0400
changeset 6180decac2433
parent 5 ccb029c396aa
child 7 4c2e4f602872
JPA parameters fix
src/main/java/ru/indvdum/jpa/init/DatabaseInitializer.java
src/test/java/ru/indvdum/jpa/tests/AbstractJPATest.java
     1.1 --- a/src/main/java/ru/indvdum/jpa/init/DatabaseInitializer.java	Sat Nov 10 22:54:48 2012 +0400
     1.2 +++ b/src/main/java/ru/indvdum/jpa/init/DatabaseInitializer.java	Sun Nov 11 01:24:41 2012 +0400
     1.3 @@ -70,9 +70,5 @@
     1.4  		dataSource.setMaxActive(2);
     1.5  
     1.6  		init(dataSource);
     1.7 -
     1.8 -		JPAPropertySelector.setSystemProperty(JPAPropertySelector.RUNTIMEENHANCEMENT, "supported");
     1.9 -		JPAPropertySelector.setSystemProperty(JPAPropertySelector.SHOWSQL, "true");
    1.10 -		JPAPropertySelector.setSystemProperty(JPAPropertySelector.SYNCHRONIZEDB, "true");
    1.11  	}
    1.12  }
     2.1 --- a/src/test/java/ru/indvdum/jpa/tests/AbstractJPATest.java	Sat Nov 10 22:54:48 2012 +0400
     2.2 +++ b/src/test/java/ru/indvdum/jpa/tests/AbstractJPATest.java	Sun Nov 11 01:24:41 2012 +0400
     2.3 @@ -2,6 +2,7 @@
     2.4  
     2.5  import org.junit.BeforeClass;
     2.6  
     2.7 +import ru.indvdum.jpa.dao.JPAPropertySelector;
     2.8  import ru.indvdum.jpa.init.DatabaseInitializer;
     2.9  
    2.10  /**
    2.11 @@ -13,6 +14,9 @@
    2.12  
    2.13  	@BeforeClass
    2.14  	public static void setUpClass() throws Exception {
    2.15 +		JPAPropertySelector.setSystemProperty(JPAPropertySelector.RUNTIMEENHANCEMENT, "supported");
    2.16 +		JPAPropertySelector.setSystemProperty(JPAPropertySelector.SHOWSQL, "true");
    2.17 +		JPAPropertySelector.setSystemProperty(JPAPropertySelector.SYNCHRONIZEDB, "true");
    2.18  		DatabaseInitializer.init();
    2.19  	}
    2.20