Skip to content

Relax message assertion for endpoint provider tests to avoid encoding issue - #7574

Merged
RanVaknin merged 2 commits into
masterfrom
rvaknin/endpoint-test-region-encoding
Nov 20, 2026
Merged

RanVaknin merged 2 commits into
masterfrom
rvaknin/endpoint-test-region-encoding

Conversation

@RanVaknin

@RanVaknin RanVaknin commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Motivation and Context

If a service's endpoint rules include the region in the error message, it will show up as the encoded region (because we use Region.of()). Service endpoint tests that assert against a non standard, non encoded region name will fail that test.

For example, a service endpoint test expects "us west 2 is not a valid region" while the SDK generates "us%20west%202 is not a valid region".

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance improvement (non-breaking change which improves latency, throughput, or resource use)
  • Deprecation (marks existing functionality as deprecated)
  • Removal (removes previously deprecated functionality)
  • Documentation (changes to documentation only)

Modifications

I made the assertion more lenient by treating decoded messages as correct as well.

Testing

Ran the endpoint provider tests or all service modules, and also ran the NetworkManager endpoint provider tests against the preview model that warranted this change. All pass.

AI tools

  • I wrote this pull request description myself, not with an AI tool
  • I have reviewed all changes in this pull request myself, including any generated by AI tools

License

  • I confirm that this pull request can be released under the Apache 2 license

@RanVaknin
RanVaknin requested a review from a team as a code owner November 19, 2026 22:09
@RanVaknin RanVaknin changed the title Relax message assertion for endpoint provider tests to avoid encoding… Relax message assertion for endpoint provider tests to avoid encoding issue Nov 19, 2026
@RanVaknin
RanVaknin enabled auto-merge November 20, 2026 00:22
@RanVaknin
RanVaknin added this pull request to the merge queue Nov 20, 2026
Merged via the queue into master with commit d4b7c1e Nov 20, 2026
16 of 20 checks passed
@github-actions

Copy link
Copy Markdown

This pull request has been closed and the conversation has been locked. Comments on closed PRs are hard for our team to see. If you need more assistance, please open a new issue that references this one.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Nov 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants