From f017e089a0a3dc825da6e820916ba4b90515a841 Mon Sep 17 00:00:00 2001 From: "Jorge C. Leitao" Date: Thu, 12 Aug 2021 06:50:26 +0000 Subject: [PATCH] Added integration tests. --- integration-testing/Cargo.toml | 2 +- integration-testing/unskip.patch | 46 ++++++++++++++++++++++++++++++++ src/ffi/schema.rs | 3 +++ 3 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 integration-testing/unskip.patch diff --git a/integration-testing/Cargo.toml b/integration-testing/Cargo.toml index f2c6e31d229..e07ae2c141f 100644 --- a/integration-testing/Cargo.toml +++ b/integration-testing/Cargo.toml @@ -30,7 +30,7 @@ publish = false logging = ["tracing-subscriber"] [dependencies] -arrow2 = { path = "../", features = ["io_ipc", "io_json_integration"], default-features = false } +arrow2 = { path = "../", features = ["io_ipc", "io_ipc_compression", "io_json_integration"], default-features = false } arrow-flight = { path = "../arrow-flight" } async-trait = "0.1.41" clap = "2.33" diff --git a/integration-testing/unskip.patch b/integration-testing/unskip.patch new file mode 100644 index 00000000000..674bea2b154 --- /dev/null +++ b/integration-testing/unskip.patch @@ -0,0 +1,46 @@ +diff --git a/dev/archery/archery/integration/datagen.py b/dev/archery/archery/integration/datagen.py +index d0c4b3d6c..936351c80 100644 +--- a/dev/archery/archery/integration/datagen.py ++++ b/dev/archery/archery/integration/datagen.py +@@ -1568,8 +1568,7 @@ def get_generated_json_files(tempdir=None): + .skip_category('Go') # TODO(ARROW-7901) + .skip_category('JS'), # TODO(ARROW-7900) + +- generate_decimal128_case() +- .skip_category('Rust'), ++ generate_decimal128_case(), + + generate_decimal256_case() + .skip_category('Go') # TODO(ARROW-7948): Decimal + Go +@@ -1579,13 +1578,11 @@ def get_generated_json_files(tempdir=None): + generate_datetime_case(), + + generate_interval_case() +- .skip_category('JS') # TODO(ARROW-5239): Intervals + JS +- .skip_category('Rust'), ++ .skip_category('JS'), # TODO(ARROW-5239): Intervals + JS + + generate_month_day_nano_interval_case() + .skip_category('Go') +- .skip_category('JS') +- .skip_category('Rust'), ++ .skip_category('JS'), + + + generate_map_case() +@@ -1603,13 +1600,11 @@ def get_generated_json_files(tempdir=None): + + generate_nested_large_offsets_case() + .skip_category('Go') +- .skip_category('JS') +- .skip_category('Rust'), ++ .skip_category('JS'), + + generate_unions_case() + .skip_category('Go') +- .skip_category('JS') +- .skip_category('Rust'), ++ .skip_category('JS'), + + generate_custom_metadata_case() + .skip_category('JS'), diff --git a/src/ffi/schema.rs b/src/ffi/schema.rs index 75a06650004..4b369a96fc6 100644 --- a/src/ffi/schema.rs +++ b/src/ffi/schema.rs @@ -323,6 +323,9 @@ fn to_format(data_type: &DataType) -> String { DataType::Duration(TimeUnit::Nanosecond) => "tDn".to_string(), DataType::Interval(IntervalUnit::YearMonth) => "tiM".to_string(), DataType::Interval(IntervalUnit::DayTime) => "tiD".to_string(), + DataType::Interval(IntervalUnit::MonthDayNano) => { + todo!("Spec for FFI for MonthDayNano still not defined.") + } DataType::Timestamp(unit, tz) => { let unit = match unit { TimeUnit::Second => "s".to_string(),