From ea238b4c4f4c936f697b5149023ce93a5d66082b Mon Sep 17 00:00:00 2001 From: Steve Ebersole Date: Mon, 4 Aug 2014 14:55:52 -0500 Subject: [PATCH] HHH-9312 - Database connection leak with JTA transaction tracking and background thread not releasing database connection --- .../hibernate/ejb/test/transaction/TransactionJoiningTest.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hibernate-entitymanager/src/test/java/org/hibernate/ejb/test/transaction/TransactionJoiningTest.java b/hibernate-entitymanager/src/test/java/org/hibernate/ejb/test/transaction/TransactionJoiningTest.java index 7c2f596694..6e0ad40272 100644 --- a/hibernate-entitymanager/src/test/java/org/hibernate/ejb/test/transaction/TransactionJoiningTest.java +++ b/hibernate-entitymanager/src/test/java/org/hibernate/ejb/test/transaction/TransactionJoiningTest.java @@ -223,7 +223,8 @@ public class TransactionJoiningTest extends BaseEntityManagerFunctionalTestCase em.createQuery( "from Book" ).getResultList(); } catch ( PersistenceException e ) { - caught = e.getCause().getClass().equals( GenericJDBCException.class ); + // slightly different expectation here now because of HHH-9312 + caught = true; } assertTrue( caught );