raulcd commented on code in PR #47461:
URL: https://github.com/apache/arrow/pull/47461#discussion_r2351903973


##########
python/pyarrow/tests/test_flight.py:
##########
@@ -2618,3 +2620,41 @@ def do_exchange(self, context, descriptor, reader, 
writer):
 
             assert received_table.equals(expected_table)
             assert reader.stats == expected_stats[command]
+
+
[email protected]
+def call_options_args(request):
+    if request.param == "default":
+        return {
+            "timeout": 3,
+            "headers": None,
+            "write_options": None,
+            "read_options": None,
+        }
+    elif request.param == "all":
+        return {
+            "timeout": 7,
+            "headers": [(b"abc", b"def")],
+            "write_options": pa.ipc.IpcWriteOptions(compression="zstd"),
+            "read_options": pa.ipc.IpcReadOptions(
+                use_threads=False,
+                ensure_alignment=pa.ipc.Alignment.DataTypeSpecific,
+            ),
+        }
+    else:
+        return {}
+
+
[email protected](
+    "call_options_args", ["default", "all"], indirect=True)
+def test_call_options_repr(call_options_args):
+    # https://github.com/apache/arrow/issues/47358
+    call_options = FlightCallOptions(**call_options_args)
+    repr = call_options.__repr__()
+
+    for arg, val in call_options_args.items():
+        if val is None:
+            continue

Review Comment:
   should we check that in the case of `IpcReadOptions`/`IpcWriteOptions` being 
`None` those are still on the returned `repr` with the default values?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to