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][exporterhelper] Fix feature gate setting for unit tests. #11927

Merged
merged 1 commit into from
Dec 18, 2024

Conversation

sfc-gh-sili
Copy link
Contributor

@sfc-gh-sili sfc-gh-sili commented Dec 17, 2024

Description

Before fix: defer setFeatureGateForTest(t, usePullingBasedExporterQueueBatcher, enableQueueBatcher)
This means run setFeatureGateForTest in the end.

After fix: defer setFeatureGateForTest(t, usePullingBasedExporterQueueBatcher, enableQueueBatcher)()
This means: run setFeatureGateForTest immediately but execute the function returned from setFeatureGateForTest in the end.

Link to tracking issue

Fixes #

Testing

Documentation

@sfc-gh-sili sfc-gh-sili requested review from bogdandrutu, dmitryax and a team as code owners December 17, 2024 07:52
@sfc-gh-sili sfc-gh-sili changed the title [chore] Fix test [chore][exporterhelper] Fix feature gate setting for unit tests. Dec 17, 2024
Copy link

codecov bot commented Dec 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.62%. Comparing base (4d8c04f) to head (27d5d42).
Report is 20 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #11927      +/-   ##
==========================================
+ Coverage   91.59%   91.62%   +0.03%     
==========================================
  Files         449      447       -2     
  Lines       23761    23729      -32     
==========================================
- Hits        21763    21741      -22     
+ Misses       1623     1613      -10     
  Partials      375      375              

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

@dmitryax dmitryax added this pull request to the merge queue Dec 18, 2024
Merged via the queue into open-telemetry:main with commit 936ef35 Dec 18, 2024
50 of 51 checks passed
@github-actions github-actions bot added this to the next release milestone Dec 18, 2024
HongChenTW pushed a commit to HongChenTW/opentelemetry-collector that referenced this pull request Dec 19, 2024
…n-telemetry#11927)

<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue.
Ex. Adding a feature - Explain what this achieves.-->
#### Description

Before fix: `defer setFeatureGateForTest(t,
usePullingBasedExporterQueueBatcher, enableQueueBatcher)`
This means run `setFeatureGateForTest` in the end.

After fix: `defer setFeatureGateForTest(t,
usePullingBasedExporterQueueBatcher, enableQueueBatcher)()`
This means: run `setFeatureGateForTest` immediately but execute the
function returned from `setFeatureGateForTest` in the end.

<!-- Issue number if applicable -->
#### Link to tracking issue
Fixes #

<!--Describe what testing was performed and which tests were added.-->
#### Testing

<!--Describe the documentation added.-->
#### Documentation

<!--Please delete paragraphs that you did not use before submitting.-->
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.

2 participants