Skip to content

test(providers/azure): reuse shared mocks in synapse/managedredis - #1470

Merged
cristim merged 1 commit into
mainfrom
chore/1466-shared-azure-mocks
Jul 21, 2026
Merged

cristim merged 1 commit into
mainfrom
chore/1466-shared-azure-mocks

Conversation

@cristim

@cristim cristim commented Jul 19, 2026

Copy link
Copy Markdown
Member

Closes #1466

Summary

  • Removes the local mockHTTPClient struct and mock HTTP response helper from providers/azure/services/synapse/client_test.go and providers/azure/services/managedredis/client_test.go.
  • Both were functionally identical to mocks.MockHTTPClient and mocks.CreateMockHTTPResponse in the shared providers/azure/mocks package, already used by compute, database, cache, cosmosdb, and search test suites.
  • No test behavior, assertions, or pass/fail semantics changed; this is a pure deduplication.

Test plan

  • gofmt -l . clean from providers/azure/
  • go vet ./... clean from providers/azure/
  • go test ./... -count=1 green across the module
  • synapse: 46 tests before and after, identical names/results
  • managedredis: 43 tests before and after, identical names/results

🤖 Generated with Claude Code

…oses #1466)

Both client_test.go files defined a local mockHTTPClient and response
helper that were functionally identical to mocks.MockHTTPClient and
mocks.CreateMockHTTPResponse already used by the other five Azure
service test suites (compute, database, cache, cosmosdb, search).
Replace the local definitions with the shared package to remove the
duplication; no test behavior or assertions changed.
@cristim cristim added triaged Item has been triaged priority/p3 Polish / idea / may never ship severity/low Minor harm urgency/eventually No deadline impact/internal Team-internal only effort/xs Trivial / one-liner type/chore Maintenance / non-user-visible labels Jul 19, 2026
@coderabbitai

coderabbitai Bot commented Jul 19, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 15 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 5b51c10d-061f-48a2-9d72-d1c0e5f806e0

📥 Commits

Reviewing files that changed from the base of the PR and between c848a07 and 1412e28.

📒 Files selected for processing (2)
  • providers/azure/services/managedredis/client_test.go
  • providers/azure/services/synapse/client_test.go
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/1466-shared-azure-mocks

Comment @coderabbitai help to get the list of available commands.

@cristim

cristim commented Jul 19, 2026

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 19, 2026 •

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@cristim
cristim merged commit c1cf552 into main Jul 21, 2026
19 checks passed
@cristim
cristim deleted the chore/1466-shared-azure-mocks branch July 27, 2026 11:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

effort/xs Trivial / one-liner impact/internal Team-internal only priority/p3 Polish / idea / may never ship severity/low Minor harm triaged Item has been triaged type/chore Maintenance / non-user-visible urgency/eventually No deadline

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore(providers/azure): reuse shared mocks package in synapse/managedredis client tests

1 participant