Skip to content

Commit

Permalink
fix: do not generate _flattened() unit tests for client streaming met…
Browse files Browse the repository at this point in the history
…hods (#1454)

The generator does not generate flattened parameters for client streamin methods, so generating unit tests for them does not make sense
  • Loading branch information
vam-google committed Sep 20, 2022
1 parent cbe3a9c commit 29610ad
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ def test_{{ method_name }}_from_dict_foreign():

{% endif %}

{% if method.flattened_fields %}
{% if method.flattened_fields and not method.client_streaming %}
def test_{{ method_name }}_flattened():
client = {{ service.client_name }}(
credentials=ga_credentials.AnonymousCredentials(),
Expand Down Expand Up @@ -1224,7 +1224,7 @@ def test_{{ method_name }}_rest_bad_request(transport: str = 'rest', request_typ
{% endif %}


{% if method.flattened_fields %}
{% if method.flattened_fields and not method.client_streaming %}
def test_{{ method_name }}_rest_flattened():
client = {{ service.client_name }}(
credentials=ga_credentials.AnonymousCredentials(),
Expand Down

0 comments on commit 29610ad

Please sign in to comment.