Skip to content

Commit

Permalink
Add test
Browse files Browse the repository at this point in the history
  • Loading branch information
viirya committed Jun 5, 2022
1 parent b928309 commit 6b6f148
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions arrow/src/ipc/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1942,4 +1942,17 @@ mod tests {
let output_batch = roundtrip_ipc_stream(&input_batch);
assert_eq!(input_batch, output_batch);
}

#[test]
fn test_no_columns_batch() {
let schema = Arc::new(Schema::new(vec![]));
let options = RecordBatchOptions {
match_field_names: true,
row_count: Some(10),
};
let input_batch =
RecordBatch::try_new_with_options(schema, vec![], &options).unwrap();
let output_batch = roundtrip_ipc_stream(&input_batch);
assert_eq!(input_batch, output_batch);
}
}

0 comments on commit 6b6f148

Please sign in to comment.