| 821 | |
| 822 | @pytest.mark.numpy |
| 823 | def test_hash_agg_empty(unary_agg_func_fixture): |
| 824 | arr1 = pa.array([], pa.float64()) |
| 825 | arr2 = pa.array([], pa.int32()) |
| 826 | table = pa.table([arr2, arr1], names=["id", "value"]) |
| 827 | |
| 828 | result = table.group_by("id").aggregate([("value", "mean_udf")]) |
| 829 | expected = pa.table([pa.array([], pa.int32()), pa.array( |
| 830 | [], pa.float64())], names=['id', 'value_mean_udf']) |
| 831 | |
| 832 | assert result == expected |
| 833 | |
| 834 | |
| 835 | def test_hash_agg_wrong_output_dtype(wrong_output_dtype_agg_func_fixture): |