Skip to content

Commit

Permalink
fix: fix test fixture
Browse files Browse the repository at this point in the history
  • Loading branch information
kysshsy committed Oct 4, 2024
1 parent d6e6d9a commit 13362f7
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/fixtures/arrow.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,12 @@ fn array_data() -> ArrayData {
}

fn single_array_data() -> ArrayData {
let values: [u8; 5] = *b"hello";
let offsets: [i32; 2] = [0, 5];
ArrayData::builder(DataType::Binary)
.len(1)
.add_buffer(Buffer::from("hello"))
.add_buffer(Buffer::from_slice_ref(&offsets[..]))
.add_buffer(Buffer::from_slice_ref(&values[..]))
.build()
.unwrap()
}
Expand Down Expand Up @@ -75,9 +78,12 @@ fn binary_array_data() -> ArrayData {
}

fn single_binary_array_data() -> ArrayData {
let values: [u8; 5] = *b"hello";
let offsets: [i32; 2] = [0, 5];
ArrayData::builder(DataType::Binary)
.len(1)
.add_buffer(Buffer::from("hello"))
.add_buffer(Buffer::from_slice_ref(&offsets[..]))
.add_buffer(Buffer::from_slice_ref(&values[..]))
.build()
.unwrap()
}
Expand Down

0 comments on commit 13362f7

Please sign in to comment.