Added test case for HHH-14125 'Selecting EntityCollection fails ("not an entity")'
This commit is contained in:
parent
9323d426f1
commit
f73fa6d132
|
@ -15,6 +15,7 @@ import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;
|
|||
|
||||
/**
|
||||
* @author Steve Ebersole
|
||||
* @author Benjamin Maurer
|
||||
*/
|
||||
public class QueryTest extends BaseCoreFunctionalTestCase {
|
||||
@Override
|
||||
|
@ -30,4 +31,13 @@ public class QueryTest extends BaseCoreFunctionalTestCase {
|
|||
s.createQuery( "from EntityWithAnElementCollection e where 'abc' member of e.someStrings" ).list();
|
||||
s.close();
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestForIssue( jiraKey = "HHH-14125" )
|
||||
public void testSelectElementCollectionProperty() {
|
||||
// Selecting property directly works for basic types and associated entities, should also work for ElementCollection
|
||||
Session s = openSession();
|
||||
s.createQuery( "select e.someStrings from EntityWithAnElementCollection e" ).list();
|
||||
s.close();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue