mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-17 08:35:13 +00:00
test code only fix
This commit is contained in:
parent
e8903540f9
commit
9225eb9f6b
@ -23,13 +23,13 @@
|
||||
*/
|
||||
package org.hibernate.test.annotations.enumerated.ormXml;
|
||||
|
||||
import org.hibernate.metamodel.spi.binding.AttributeBinding;
|
||||
import org.hibernate.type.CustomType;
|
||||
import org.hibernate.type.EnumType;
|
||||
import org.hibernate.type.Type;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
import org.hibernate.testing.FailureExpectedWithNewMetamodel;
|
||||
import org.hibernate.testing.TestForIssue;
|
||||
import org.hibernate.testing.junit4.BaseCoreFunctionalTestCase;
|
||||
import org.hibernate.testing.junit4.ExtraAssertions;
|
||||
@ -39,7 +39,6 @@
|
||||
/**
|
||||
* @author Steve Ebersole
|
||||
*/
|
||||
@FailureExpectedWithNewMetamodel
|
||||
@TestForIssue( jiraKey = "HHH-7645" )
|
||||
public class OrmXmlEnumTypeTest extends BaseCoreFunctionalTestCase {
|
||||
@Override
|
||||
@ -49,9 +48,11 @@ protected String[] getXmlFiles() {
|
||||
|
||||
@Test
|
||||
public void testOrmXmlDefinedEnumType() {
|
||||
Type bindingPropertyType = configuration().getClassMapping( BookWithOrmEnum.class.getName() )
|
||||
.getProperty( "bindingStringEnum" )
|
||||
.getType();
|
||||
AttributeBinding attributeBinding = metadata().getEntityBinding( BookWithOrmEnum.class.getName() )
|
||||
.locateAttributeBinding( "bindingStringEnum" );
|
||||
Type bindingPropertyType =
|
||||
attributeBinding.getHibernateTypeDescriptor()
|
||||
.getResolvedTypeMapping();
|
||||
CustomType customType = ExtraAssertions.assertTyping( CustomType.class, bindingPropertyType );
|
||||
EnumType enumType = ExtraAssertions.assertTyping( EnumType.class, customType.getUserType() );
|
||||
assertFalse( enumType.isOrdinal() );
|
||||
|
Loading…
x
Reference in New Issue
Block a user