Skip to content

Commit

Permalink
Updating the SQL tests to include JdbcToArrowConfig versions.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Pigott committed Dec 8, 2018
1 parent b270044 commit df632e3
Show file tree
Hide file tree
Showing 5 changed files with 44 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@

import org.apache.arrow.adapter.jdbc.AbstractJdbcToArrowTest;
import org.apache.arrow.adapter.jdbc.JdbcToArrow;
import org.apache.arrow.adapter.jdbc.JdbcToArrowConfig;
import org.apache.arrow.adapter.jdbc.Table;
import org.apache.arrow.memory.RootAllocator;
import org.apache.arrow.vector.VarCharVector;
Expand Down Expand Up @@ -116,6 +117,13 @@ public void testJdbcToArroValues() throws SQLException, IOException {
new RootAllocator(Integer.MAX_VALUE)));
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()),
Calendar.getInstance()));
testDataSets(JdbcToArrow.sqlToArrow(
conn.createStatement().executeQuery(table.getQuery()),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
testDataSets(JdbcToArrow.sqlToArrow(
conn,
table.getQuery(),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@

import org.apache.arrow.adapter.jdbc.AbstractJdbcToArrowTest;
import org.apache.arrow.adapter.jdbc.JdbcToArrow;
import org.apache.arrow.adapter.jdbc.JdbcToArrowConfig;
import org.apache.arrow.adapter.jdbc.Table;
import org.apache.arrow.memory.RootAllocator;
import org.apache.arrow.vector.BigIntVector;
Expand Down Expand Up @@ -142,6 +143,13 @@ public void testJdbcToArroValues() throws SQLException, IOException {
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()),
new RootAllocator(Integer.MAX_VALUE)));
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()), Calendar.getInstance()));
testDataSets(JdbcToArrow.sqlToArrow(
conn.createStatement().executeQuery(table.getQuery()),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
testDataSets(JdbcToArrow.sqlToArrow(
conn,
table.getQuery(),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@

import org.apache.arrow.adapter.jdbc.AbstractJdbcToArrowTest;
import org.apache.arrow.adapter.jdbc.JdbcToArrow;
import org.apache.arrow.adapter.jdbc.JdbcToArrowConfig;
import org.apache.arrow.adapter.jdbc.Table;
import org.apache.arrow.memory.RootAllocator;
import org.apache.arrow.vector.BigIntVector;
Expand Down Expand Up @@ -99,6 +100,13 @@ public void testJdbcToArroValues() throws SQLException, IOException {
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()),
new RootAllocator(Integer.MAX_VALUE)));
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()), Calendar.getInstance()));
testDataSets(JdbcToArrow.sqlToArrow(
conn.createStatement().executeQuery(table.getQuery()),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
testDataSets(JdbcToArrow.sqlToArrow(
conn,
table.getQuery(),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@

import org.apache.arrow.adapter.jdbc.AbstractJdbcToArrowTest;
import org.apache.arrow.adapter.jdbc.JdbcToArrow;
import org.apache.arrow.adapter.jdbc.JdbcToArrowConfig;
import org.apache.arrow.adapter.jdbc.Table;
import org.apache.arrow.memory.RootAllocator;
import org.apache.arrow.vector.BigIntVector;
Expand Down Expand Up @@ -133,6 +134,13 @@ public void testJdbcToArroValues() throws SQLException, IOException {
new RootAllocator(Integer.MAX_VALUE)));
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()),
Calendar.getInstance()));
testDataSets(JdbcToArrow.sqlToArrow(
conn.createStatement().executeQuery(table.getQuery()),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
testDataSets(JdbcToArrow.sqlToArrow(
conn,
table.getQuery(),
new JdbcToArrowConfig(new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance())));
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

import org.apache.arrow.adapter.jdbc.AbstractJdbcToArrowTest;
import org.apache.arrow.adapter.jdbc.JdbcToArrow;
import org.apache.arrow.adapter.jdbc.JdbcToArrowConfig;
import org.apache.arrow.adapter.jdbc.Table;
import org.apache.arrow.memory.RootAllocator;
import org.apache.arrow.vector.DateMilliVector;
Expand Down Expand Up @@ -105,6 +106,17 @@ public void testJdbcToArroValues() throws SQLException, IOException {
new RootAllocator(Integer.MAX_VALUE), Calendar.getInstance(TimeZone.getTimeZone(table.getTimezone()))));
testDataSets(JdbcToArrow.sqlToArrow(conn.createStatement().executeQuery(table.getQuery()),
Calendar.getInstance(TimeZone.getTimeZone(table.getTimezone()))));
testDataSets(JdbcToArrow.sqlToArrow(
conn.createStatement().executeQuery(table.getQuery()),
new JdbcToArrowConfig(
new RootAllocator(Integer.MAX_VALUE),
Calendar.getInstance(TimeZone.getTimeZone(table.getTimezone())))));
testDataSets(JdbcToArrow.sqlToArrow(
conn,
table.getQuery(),
new JdbcToArrowConfig(
new RootAllocator(Integer.MAX_VALUE),
Calendar.getInstance(TimeZone.getTimeZone(table.getTimezone())))));
}

/**
Expand Down

0 comments on commit df632e3

Please sign in to comment.