(start_type, widened_type)
| 4732 | @pytest.mark.parametrize("start_type, widened_type", [(pa.int8(), pa.int16()), |
| 4733 | (pa.uint8(), pa.uint16())]) |
| 4734 | def test_dictionary_array_index_width_adapts(start_type, widened_type): |
| 4735 | # The index width adapts to the number of distinct values, as it does for signed |
| 4736 | # indices; only the signedness of the requested type is preserved. |
| 4737 | values = [str(i) for i in range(200)] |
| 4738 | arr = pa.array(values, type=pa.dictionary(start_type, pa.string())) |
| 4739 | assert arr.type == pa.dictionary(widened_type, pa.string()) |
| 4740 | assert arr.to_pylist() == values |
| 4741 | |
| 4742 | |
| 4743 | @pytest.mark.pandas |
nothing calls this directly
no test coverage detected