Assert buildObserver on counter and up-down-counter in shared default meter test#8611
Open
thswlsqls wants to merge 1 commit into
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8611 +/- ##
============================================
+ Coverage 91.63% 91.66% +0.02%
Complexity 10326 10326
============================================
Files 1013 1013
Lines 27295 27295
Branches 3205 3205
============================================
+ Hits 25011 25019 +8
+ Misses 1558 1550 -8
Partials 726 726 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
AbstractDefaultMeterTestcalledbuildObserver()only on the two gauge builders.buildObserver(), and both no-op meters (DefaultMeter,ExtendedDefaultMeter) override all six. The eight counter and up-down-counter overrides (4 builders x 2 impls) were never executed by any test.buildObserver()withrecord(value)andrecord(value, Attributes)to the four existing counter and up-down-counter tests, in the same shape as the gauge tests.Testing done
./gradlew :api:all:test --tests DefaultMeterTest— 18 passed../gradlew :api:incubator:test --tests ExtendedDefaultMeterTest— 19 passed../gradlew :api:testing-internal:checkpassed.UnsupportedOperationExceptioninDefaultMeter's long-counterbuildObserver(), the old test still passed and the new one failed. Probe reverted.