Skip to content

Commit

Permalink
Disable tests broken by Hive breaking changes
Browse files Browse the repository at this point in the history
  • Loading branch information
findepi committed Sep 30, 2019
1 parent 545e586 commit 64d4090
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import static com.google.common.base.Preconditions.checkState;
import static java.lang.Integer.parseInt;
import static java.util.Objects.requireNonNull;
import static org.assertj.core.api.Assertions.assertThatThrownBy;

public class TestHive
extends AbstractTestHive
Expand Down Expand Up @@ -72,4 +73,32 @@ public void testGetPartitionSplitsTableOfflinePartition()

super.testGetPartitionSplitsTableOfflinePartition();
}

@Override
public void testTypesRcBinary()
throws Exception
{
if (getHiveVersionMajor() >= 3) {
// TODO (https://github.com/prestosql/presto/issues/1218) requires https://issues.apache.org/jira/browse/HIVE-22167
assertThatThrownBy(super::testTypesRcBinary)
.isInstanceOf(AssertionError.class)
.hasMessage("expected [2011-05-06 01:23:09.123] but found [2011-05-06 07:08:09.123]");
return;
}
super.testTypesRcBinary();
}

@Override
public void testTypesParquet()
throws Exception
{
if (getHiveVersionMajor() >= 3) {
// TODO (https://github.com/prestosql/presto/issues/1218) requires https://issues.apache.org/jira/browse/HIVE-21002
assertThatThrownBy(super::testTypesParquet)
.isInstanceOf(AssertionError.class)
.hasMessage("expected [2011-05-06 01:23:09.123] but found [2011-05-06 07:08:09.123]");
return;
}
super.testTypesParquet();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
*/
package io.prestosql.tests.hive;

import io.prestosql.tempto.ProductTest;
import io.prestosql.tempto.Requirement;
import io.prestosql.tempto.Requirements;
import io.prestosql.tempto.RequirementsProvider;
Expand Down Expand Up @@ -65,7 +64,7 @@
import static java.sql.JDBCType.VARCHAR;

public class TestAllDatatypesFromHiveConnector
extends ProductTest
extends HiveProductTest
{
public static final class TextRequirements
implements RequirementsProvider
Expand Down Expand Up @@ -276,7 +275,10 @@ public void testSelectAllDatatypesAvro()
234.567,
new BigDecimal("346"),
new BigDecimal("345.67800"),
Timestamp.valueOf(LocalDateTime.of(2015, 5, 10, 12, 15, 35, 123_000_000)),
getHiveVersionMajor() < 3
? Timestamp.valueOf(LocalDateTime.of(2015, 5, 10, 12, 15, 35, 123_000_000))
// TODO (https://github.com/prestosql/presto/issues/1218) requires https://issues.apache.org/jira/browse/HIVE-21002
: Timestamp.valueOf(LocalDateTime.of(2015, 5, 10, 18, 0, 35, 123_000_000)),
Date.valueOf("2015-05-10"),
"ala ma kota",
"ala ma kot",
Expand Down Expand Up @@ -395,7 +397,10 @@ public void testSelectAllDatatypesParquetFile()
234.567,
new BigDecimal("346"),
new BigDecimal("345.67800"),
Timestamp.valueOf(LocalDateTime.of(2015, 5, 10, 12, 15, 35, 123_000_000)),
getHiveVersionMajor() < 3
? Timestamp.valueOf(LocalDateTime.of(2015, 5, 10, 12, 15, 35, 123_000_000))
// TODO (https://github.com/prestosql/presto/issues/1218) requires https://issues.apache.org/jira/browse/HIVE-21002
: Timestamp.valueOf(LocalDateTime.of(2015, 5, 10, 18, 0, 35, 123_000_000)),
"ala ma kota",
"ala ma kot",
"ala ma ",
Expand Down

0 comments on commit 64d4090

Please sign in to comment.