diff --git a/hibernate-core/src/test/java/org/hibernate/test/type/LocalTimeTest.java b/hibernate-core/src/test/java/org/hibernate/test/type/LocalTimeTest.java index 36bceb0235..73a5ad6b70 100644 --- a/hibernate-core/src/test/java/org/hibernate/test/type/LocalTimeTest.java +++ b/hibernate-core/src/test/java/org/hibernate/test/type/LocalTimeTest.java @@ -15,6 +15,7 @@ import java.sql.Types; import java.time.LocalTime; import java.time.ZoneId; import java.util.Arrays; +import java.util.Collections; import java.util.List; import javax.persistence.Basic; import javax.persistence.Column; @@ -56,6 +57,18 @@ public class LocalTimeTest extends AbstractJavaTimeTypeTest getHibernateJdbcTimeZonesToTest() { + // The MariaDB Connector/J JDBC driver has a bug in ResultSet#getTime(int, Calendar) + // that prevents our explicit JDBC timezones from being recognized + // See https://hibernate.atlassian.net/browse/HHH-13581 + // See https://jira.mariadb.org/browse/CONJ-724 + if ( MariaDBDialect.class.isInstance( getDialect() ) ) { + return Collections.emptySet(); + } + return super.getHibernateJdbcTimeZonesToTest(); + } } @Parameterized.Parameters(name = "{1}:{2}:{3}.{4} (JDBC write date: {5}-{6}-{7}) {0}") diff --git a/hibernate-core/src/test/java/org/hibernate/test/type/OffsetTimeTest.java b/hibernate-core/src/test/java/org/hibernate/test/type/OffsetTimeTest.java index cb83f66941..16bef9c237 100644 --- a/hibernate-core/src/test/java/org/hibernate/test/type/OffsetTimeTest.java +++ b/hibernate-core/src/test/java/org/hibernate/test/type/OffsetTimeTest.java @@ -17,6 +17,7 @@ import java.time.OffsetTime; import java.time.ZoneId; import java.time.ZoneOffset; import java.util.Arrays; +import java.util.Collections; import java.util.List; import javax.persistence.Basic; import javax.persistence.Column; @@ -59,6 +60,18 @@ public class OffsetTimeTest extends AbstractJavaTimeTypeTest getHibernateJdbcTimeZonesToTest() { + // The MariaDB Connector/J JDBC driver has a bug in ResultSet#getTime(int, Calendar) + // that prevents our explicit JDBC timezones from being recognized + // See https://hibernate.atlassian.net/browse/HHH-13581 + // See https://jira.mariadb.org/browse/CONJ-724 + if ( MariaDBDialect.class.isInstance( getDialect() ) ) { + return Collections.emptySet(); + } + return super.getHibernateJdbcTimeZonesToTest(); + } } @Parameterized.Parameters(name = "{1}:{2}:{3}.{4}[{5}] (JDBC write date: {6}-{7}-{8}) {0}")