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

Commit f192273

Browse files
committed
add test
1 parent 262c60e commit f192273

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tests/unit/test_path_template.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -626,6 +626,14 @@ def test_transcode_with_additional_bindings(
626626
auth_pb2.AuthenticationRule(selector="first"),
627627
{},
628628
],
629+
# Test trailing underscore in body is removed during transcoding
630+
# See https://github.com/googleapis/python-api-core/issues/490
631+
[[["post", "/v1/{name}", "data"]], None, {"name": "first/last"}],
632+
[
633+
[["post", "/v1/{selector}", "data_"]],
634+
auth_pb2.AuthenticationRule(selector="first"),
635+
{},
636+
],
629637
[[["post", "/v1/{first_name}", "data"]], None, {"last_name": "last"}],
630638
[
631639
[["post", "/v1/{first_name}", ""]],

0 commit comments

Comments
 (0)