Skip to content

[CODE HEALTH] Move ext and exporters test classes into anonymous namespace#4225

Open
mateenali66 wants to merge 1 commit into
open-telemetry:mainfrom
mateenali66:code-health/4196-ext-exporters-anon-namespace
Open

[CODE HEALTH] Move ext and exporters test classes into anonymous namespace#4225
mateenali66 wants to merge 1 commit into
open-telemetry:mainfrom
mateenali66:code-health/4196-ext-exporters-anon-namespace

Conversation

@mateenali66

Copy link
Copy Markdown
Contributor

Continues the misc-use-internal-linkage cleanup from #4196, picking up the ext and exporters test files thc1006 left open in #4217.

Moves the test fixtures and helpers into anonymous namespaces so they get internal linkage:

  • ext/test/http/url_parser_test: ParsedUrl, UrlParserTests, UrlDecoderTests
  • exporters/ostream/test/ostream_span_test: TestResource
  • exporters/memory/test/in_memory_metric_exporter_test: InMemoryMetricExporterTest

Test-only, no behavior change. Lowered the clang-tidy warning_limit by 5 for both ABI presets.

Part of #4196.

@mateenali66 mateenali66 requested a review from a team as a code owner July 8, 2026 19:43
…space

Give the test fixtures and helpers in ext/test/http/url_parser_test,
exporters/ostream/test/ostream_span_test and
exporters/memory/test/in_memory_metric_exporter_test internal linkage by
moving them into an anonymous namespace, clearing the remaining
misc-use-internal-linkage warnings in those files. Lower the clang-tidy
warning_limit accordingly.

Part of open-telemetry#4196.

Signed-off-by: Mateen Anjum <mateenali66@gmail.com>
@codecov

codecov Bot commented Jul 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.80%. Comparing base (dcd4977) to head (3838f86).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #4225   +/-   ##
=======================================
  Coverage   82.80%   82.80%           
=======================================
  Files         415      415           
  Lines       17452    17452           
=======================================
  Hits        14449    14449           
  Misses       3003     3003           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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