Skip to content
This repository was archived by the owner on Apr 1, 2026. It is now read-only.

Commit 50aefef

Browse files
committed
Fixed tests on Python 3.7
1 parent c6fd3ad commit 50aefef

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

tests/unit/admin_overlay/test_client.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,11 @@ def test_bigtable_table_admin_client_client_version(transport_class, transport_n
5858
with mock.patch.object(transport_class, "__init__") as patched:
5959
patched.return_value = None
6060
BigtableTableAdminClient(transport=transport_name)
61-
transport_init_call = patched.call_args
62-
assert transport_init_call.kwargs["client_info"] == DEFAULT_CLIENT_INFO
61+
62+
# call_args.kwargs is not supported in Python 3.7, so find them from the tuple
63+
# instead. It's always the last item in the call_args tuple.
64+
transport_init_call_kwargs = patched.call_args[-1]
65+
assert transport_init_call_kwargs["client_info"] == DEFAULT_CLIENT_INFO
6366

6467
assert (
6568
DEFAULT_CLIENT_INFO.client_library_version

0 commit comments

Comments
 (0)