Skip to content

impl(oauth2): add AllowedLocations methods to minimal iam rest stub#16067

Open
scotthart wants to merge 1 commit intogoogleapis:mainfrom
scotthart:rab_minimal_iam_2
Open

impl(oauth2): add AllowedLocations methods to minimal iam rest stub#16067
scotthart wants to merge 1 commit intogoogleapis:mainfrom
scotthart:rab_minimal_iam_2

Conversation

@scotthart
Copy link
Copy Markdown
Member

Adds methods to get the allowed locations from the IAM credentials REST endpoint.

@scotthart scotthart requested a review from a team as a code owner April 6, 2026 20:34
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request implements the AllowedLocations functionality within the IAM Credentials REST client, supporting service accounts, workload identities, and workforce identities. It also introduces a ValidateStringArrayField utility for JSON parsing. The review feedback identifies that the AllowedLocations endpoint should use the GET method instead of POST, necessitating the removal of the request payload and updates to mock expectations in tests. Additionally, a copy-paste error was found in the unit tests for the new JSON parsing utility.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 6, 2026

Codecov Report

❌ Patch coverage is 86.33333% with 41 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.68%. Comparing base (fc9f8f0) to head (24b116f).

Files with missing lines Patch % Lines
...ud/internal/oauth2_minimal_iam_credentials_rest.cc 56.97% 37 Missing ⚠️
...h2_impersonate_service_account_credentials_test.cc 0.00% 3 Missing ⚠️
google/cloud/internal/json_parsing.cc 87.50% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #16067      +/-   ##
==========================================
- Coverage   92.69%   92.68%   -0.01%     
==========================================
  Files        2343     2343              
  Lines      216674   216959     +285     
==========================================
+ Hits       200852   201097     +245     
- Misses      15822    15862      +40     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant