HHH-13663 Have the test actually use ThreadLocalSessionContext
This commit is contained in:
parent
1d64a386cd
commit
14b6330a32
|
@ -29,9 +29,10 @@ public class TestHibernateFlushModeOnThreadLocalInactiveTransaction extends Base
|
|||
|
||||
@Test
|
||||
public void testHibernateFlushModeOnInactiveTransaction() {
|
||||
Session s = openSession();
|
||||
//s.setFlushMode(FlushMode.AUTO); // this does not throw (API is deprecated)
|
||||
s.setHibernateFlushMode( FlushMode.AUTO ); // this should not throw even within an inactive transaction
|
||||
try ( Session s = sessionFactory().getCurrentSession() ) {
|
||||
//s.setFlushMode( FlushMode.AUTO ); // this does not throw (API is deprecated)
|
||||
s.setHibernateFlushMode( FlushMode.AUTO ); // this should not throw even within an inactive transaction
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue