Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -885,7 +885,7 @@ def search_profiles(

Returns:
A :class:`~google.gax.PageIterator` instance. By default, this
is an iterable of :class:`~google.cloud.talent_v4beta1.types.HistogramQueryResult` instances.
is an iterable of :class:`~google.cloud.talent_v4beta1.types.SummarizedProfile` instances.
This object can also be configured to iterate over the pages
of the response through the `options` parameter.

Expand Down Expand Up @@ -940,7 +940,7 @@ def search_profiles(
metadata=metadata,
),
request=request,
items_field="histogram_query_results",
items_field="summarized_profiles",
request_token_field="page_token",
response_token_field="next_page_token",
)
Expand Down
6 changes: 3 additions & 3 deletions talent/synth.metadata
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"updateTime": "2019-05-09T18:09:29.492318Z",
"updateTime": "2019-05-14T12:28:53.074035Z",
"sources": [
{
"generator": {
Expand All @@ -12,8 +12,8 @@
"git": {
"name": "googleapis",
"remote": "https://github.com/googleapis/googleapis.git",
"sha": "f86c9531dc49d41267e2117ece1ea29840f15ce3",
"internalRef": "247457584"
"sha": "ffa256646fb15c4a6c720f0ed8f984a0ea513416",
"internalRef": "248066377"
}
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@

from google.cloud import talent_v4beta1
from google.cloud.talent_v4beta1.proto import common_pb2
from google.cloud.talent_v4beta1.proto import histogram_pb2
from google.cloud.talent_v4beta1.proto import profile_pb2
from google.cloud.talent_v4beta1.proto import profile_service_pb2
from google.protobuf import empty_pb2
Expand Down Expand Up @@ -303,12 +302,12 @@ def test_search_profiles(self):
# Setup Expected Response
estimated_total_size = 1882144769
next_page_token = ""
histogram_query_results_element = {}
histogram_query_results = [histogram_query_results_element]
summarized_profiles_element = {}
summarized_profiles = [summarized_profiles_element]
expected_response = {
"estimated_total_size": estimated_total_size,
"next_page_token": next_page_token,
"histogram_query_results": histogram_query_results,
"summarized_profiles": summarized_profiles,
}
expected_response = profile_service_pb2.SearchProfilesResponse(
**expected_response
Expand All @@ -329,7 +328,7 @@ def test_search_profiles(self):
resources = list(paged_list_response)
assert len(resources) == 1

assert expected_response.histogram_query_results[0] == resources[0]
assert expected_response.summarized_profiles[0] == resources[0]

assert len(channel.requests) == 1
expected_request = profile_service_pb2.SearchProfilesRequest(
Expand Down