From c5972d0fa43b2edbc437d6ff3adcf1e1e4246ee6 Mon Sep 17 00:00:00 2001 From: Andrew Lamb Date: Thu, 16 Jan 2025 05:54:22 -0500 Subject: [PATCH] Update `parquet-testing` pin, add tests for new invalid data (#6984) * Update parquet-testing pin * Add a test for ARROW-GH-45185.parquet --- parquet-testing | 2 +- parquet/tests/arrow_reader/bad_data.rs | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/parquet-testing b/parquet-testing index 4439a223a315..f4d7ed772a62 160000 --- a/parquet-testing +++ b/parquet-testing @@ -1 +1 @@ -Subproject commit 4439a223a315cf874746d3b5da25e6a6b2a2b16e +Subproject commit f4d7ed772a62a95111db50fbcad2460833e8c882 diff --git a/parquet/tests/arrow_reader/bad_data.rs b/parquet/tests/arrow_reader/bad_data.rs index cfd61e82d32b..7de5d7e346d6 100644 --- a/parquet/tests/arrow_reader/bad_data.rs +++ b/parquet/tests/arrow_reader/bad_data.rs @@ -30,6 +30,7 @@ static KNOWN_FILES: &[&str] = &[ "ARROW-GH-43605.parquet", "ARROW-RS-GH-6229-DICTHEADER.parquet", "ARROW-RS-GH-6229-LEVELS.parquet", + "ARROW-GH-45185.parquet", "README.md", ]; @@ -120,6 +121,16 @@ fn test_arrow_rs_gh_6229_dict_levels() { ); } +#[test] +#[cfg(feature = "snap")] +fn test_arrow_rs_gh_45185_dict_levels() { + let err = read_file("ARROW-GH-45185.parquet").unwrap_err(); + assert_eq!( + err.to_string(), + "External: Parquet argument error: Parquet error: first repetition level of batch must be 0" + ); +} + /// Reads the file and tries to return the total row count /// Returns an error if the file is invalid fn read_file(name: &str) -> Result {