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] Make config validation tests more resilient #37579

Merged
merged 1 commit into from
Jan 30, 2025

Conversation

evan-bradley
Copy link
Contributor

Description

Fixes some errors introduced by open-telemetry/opentelemetry-collector#12108.

Overall this makes tests that check errors resulting from config validation more resilient by only checking that the error message contains the information relevant to the component. The tests changed in this PR make more precise assumptions about the error message that no longer hold up if component.ValidateConfig returns errors with different internal structures or messages.

I've run this locally with the changes in open-telemetry/opentelemetry-collector#12108, but I encountered some issues that prevented running tests locally in some modules, so not all errors may be fixed. I will play more with this tomorrow, but I also think it's safe to merge this as-is and fix the remaining errors during a make update-otel PR.

@mx-psi mx-psi merged commit 79a2527 into open-telemetry:main Jan 30, 2025
164 checks passed
@github-actions github-actions bot added this to the next release milestone Jan 30, 2025
mx-psi pushed a commit that referenced this pull request Jan 31, 2025
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue.
Ex. Adding a feature - Explain what this achieves.-->
#### Description

Follow up to
#37579.
This should address issues with the remaining tests.
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.

4 participants