HH-13550 : Fix Oracle failure for test added by HHH-13424

This commit is contained in:
Gail Badner 2019-08-09 17:28:42 -07:00
parent 2a018ffcb4
commit cb51b1e838
1 changed files with 12 additions and 17 deletions

View File

@ -47,12 +47,10 @@ public class SingleTableNullNonOptionalSecondaryTableTest extends AbstractNonOpt
assertNotNull( anEntity );
assertNull( anEntity.aDetail );
// assert that a row was inserted into Details when its property is null
assertEquals(
1,
entityManager.createNativeQuery(
final Number id = (Number) entityManager.createNativeQuery(
"select id from Details where aDetail is null"
).getSingleResult()
);
).getSingleResult();
assertEquals( 1, id.intValue() );
}
);
}
@ -71,18 +69,15 @@ public class SingleTableNullNonOptionalSecondaryTableTest extends AbstractNonOpt
assertNotNull( anEntity );
assertNull( anEntity.aDetail );
// assert that a row was inserted into Details when its property is null
assertEquals(
1,
entityManager.createNativeQuery(
Number id = (Number) entityManager.createNativeQuery(
"select id from Details where aDetail is null"
).getSingleResult()
);
).getSingleResult();
assertEquals( 1, id.intValue() );
// assert that a row was inserted into MoreDetails when its property is null
assertEquals( 1,
entityManager.createNativeQuery(
id = (Number) entityManager.createNativeQuery(
"select id from MoreDetails where anotherDetail is null"
).getSingleResult()
);
).getSingleResult();
assertEquals( 1, id.intValue() );
}
);
}