Skip to content

Commit 4a160c9

Browse files
committed
Hopefully fix R tests + Nit
1 parent d13af71 commit 4a160c9

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

cpp/src/parquet/arrow/arrow_reader_writer_test.cc

+2-4
Original file line numberDiff line numberDiff line change
@@ -3337,6 +3337,7 @@ TEST(TestArrowReadWrite, NonUniqueDictionaryValues) {
33373337
}
33383338

33393339
TEST(TestArrowReadWrite, DictionaryIndexBitwidthRoundtrip) {
3340+
// GH-30302: the bitwidth of Arrow dictionary indices should be preserved
33403341
for (const auto& index_type :
33413342
{::arrow::int8(), ::arrow::int16(), ::arrow::int32(), ::arrow::int64()}) {
33423343
ARROW_SCOPED_TRACE("index_type = ", *index_type);
@@ -3349,10 +3350,7 @@ TEST(TestArrowReadWrite, DictionaryIndexBitwidthRoundtrip) {
33493350
DictArrayFromJSON(dict_type, R"([2, 0, 1, 0, 2])",
33503351
R"(["first", "second", "third"])"),
33513352
};
3352-
std::vector<std::shared_ptr<ChunkedArray>> columns = {};
3353-
columns.emplace_back(std::make_shared<ChunkedArray>(dict_arrays));
3354-
3355-
auto table = Table::Make(schema, columns);
3353+
auto table = Table::Make(schema, {std::make_shared<ChunkedArray>(dict_arrays)});
33563354
auto arrow_writer_props =
33573355
parquet::ArrowWriterProperties::Builder().store_schema()->build();
33583356

r/tests/testthat/test-dataset.R

+1-1
Original file line numberDiff line numberDiff line change
@@ -915,7 +915,7 @@ test_that("Dataset and query print methods", {
915915
"dbl: double",
916916
"lgl: bool",
917917
"chr: string",
918-
"fct: dictionary<values=string, indices=int32>",
918+
"fct: dictionary<values=string, indices=int8>",
919919
"ts: timestamp[us, tz=UTC]",
920920
"group: int32",
921921
"other: string",

0 commit comments

Comments
 (0)