Skip to content

Adds an Attribute assertion to metric data test#3487

Merged
MadVikingGod merged 7 commits into
open-telemetry:mainfrom
MadVikingGod:mvg/attribute-checker
Nov 29, 2022
Merged

Adds an Attribute assertion to metric data test#3487
MadVikingGod merged 7 commits into
open-telemetry:mainfrom
MadVikingGod:mvg/attribute-checker

Conversation

@MadVikingGod
Copy link
Copy Markdown
Contributor

This is an attempt to solve the immediate problem of #3435.

It creates a new Assert function that will check if the attributes on ALL DataPoints contain the Attributes provided.

@codecov
Copy link
Copy Markdown

codecov Bot commented Nov 21, 2022

Codecov Report

Attention: Patch coverage is 95.04132% with 6 lines in your changes missing coverage. Please review.

Project coverage is 78.0%. Comparing base (d7b3115) to head (6774d23).
Report is 1824 commits behind head on main.

Files with missing lines Patch % Lines
sdk/metric/metricdata/metricdatatest/assertion.go 89.1% 4 Missing ⚠️
...dk/metric/metricdata/metricdatatest/comparisons.go 97.6% 2 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##            main   #3487     +/-   ##
=======================================
+ Coverage   77.9%   78.0%   +0.1%     
=======================================
  Files        165     165             
  Lines      11634   11755    +121     
=======================================
+ Hits        9066    9179    +113     
- Misses      2372    2380      +8     
  Partials     196     196             
Files with missing lines Coverage Δ
...dk/metric/metricdata/metricdatatest/comparisons.go 97.5% <97.6%> (+<0.1%) ⬆️
sdk/metric/metricdata/metricdatatest/assertion.go 80.6% <89.1%> (+5.2%) ⬆️

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@MadVikingGod MadVikingGod merged commit 289a612 into open-telemetry:main Nov 29, 2022
@MadVikingGod MadVikingGod deleted the mvg/attribute-checker branch November 29, 2022 20:32
@MrAlias MrAlias added this to the Metric v0.34.0 milestone Dec 6, 2022
@MrAlias MrAlias mentioned this pull request Jan 28, 2023
@MrAlias MrAlias added the area:metrics Part of OpenTelemetry Metrics label Jun 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:metrics Part of OpenTelemetry Metrics

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants