mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-15 23:55:05 +00:00
HHH-16311 - Fix HANA test issues
This commit is contained in:
parent
d5e0f064ac
commit
67ba0decd8
@ -12,9 +12,8 @@
|
||||
import org.hibernate.boot.MetadataSources;
|
||||
import org.hibernate.boot.registry.StandardServiceRegistry;
|
||||
import org.hibernate.type.ConvertedBasicType;
|
||||
import org.hibernate.type.CustomType;
|
||||
import org.hibernate.type.EnumType;
|
||||
import org.hibernate.type.Type;
|
||||
import org.hibernate.type.descriptor.jdbc.spi.JdbcTypeRegistry;
|
||||
|
||||
import org.hibernate.testing.ServiceRegistryBuilder;
|
||||
import org.hibernate.testing.TestForIssue;
|
||||
@ -23,7 +22,6 @@
|
||||
import org.junit.Test;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertFalse;
|
||||
|
||||
/**
|
||||
* @author Steve Ebersole
|
||||
@ -44,8 +42,14 @@ public void testOrmXmlDefinedEnumType() {
|
||||
.getProperty( "bindingStringEnum" )
|
||||
.getType();
|
||||
|
||||
final JdbcTypeRegistry jdbcTypeRegistry = metadata.getDatabase()
|
||||
.getTypeConfiguration()
|
||||
.getJdbcTypeRegistry();
|
||||
ConvertedBasicType<?> enumMapping = ExtraAssertions.assertTyping( ConvertedBasicType.class, bindingPropertyType );
|
||||
assertEquals( Types.VARCHAR, enumMapping.getJdbcType().getJdbcTypeCode() );
|
||||
assertEquals(
|
||||
jdbcTypeRegistry.getDescriptor( Types.VARCHAR ),
|
||||
jdbcTypeRegistry.getDescriptor( enumMapping.getJdbcType().getJdbcTypeCode() )
|
||||
);
|
||||
}
|
||||
finally {
|
||||
ServiceRegistryBuilder.destroy( ssr );
|
||||
|
Loading…
x
Reference in New Issue
Block a user