Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[chore] Remove usages of extensionauthtest.MockClient #38401

Merged

Conversation

mx-psi
Copy link
Member

@mx-psi mx-psi commented Mar 5, 2025

Description

All usages of extensionauthtest.MockClient can be replaced by a simple extensionauth.NewClient + passing the appropriate options.

There is one use case that is maybe useful to have a helper for: errors, which are used in confighttp tests.

This PR removes usages of extensionauthtest.MockClient so that we can remove the MockClient and replace it with something that allows for a sealed interface/struct for extensionauth.Client

@mx-psi mx-psi merged commit 9aab87e into open-telemetry:main Mar 5, 2025
156 checks passed
@github-actions github-actions bot added this to the next release milestone Mar 5, 2025
github-merge-queue bot pushed a commit to open-telemetry/opentelemetry-collector that referenced this pull request Mar 6, 2025
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue.
Ex. Adding a feature - Explain what this achieves.-->
#### Description

Removes `extensionauthtest.MockClient`. Users can use either
`extensionauth.NewClient` or use `extensionauthtest.NewErrorClient` as a
convenience method to replicate the `MustError` field behavior.

Doing a Github search, I am unable to find usages of this outside of
contrib, which I dealt with on PR
open-telemetry/opentelemetry-collector-contrib/pull/38401, thus I
believe this should be fine to remove in one go.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants