You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@mbehr1:
maybe you can help, it seems you wrote most of the unit-tests:
my changes add a dependency on the options global to MeterS0.cpp,
(so that if if single-shot mode is enabled, MeterS0 can generate a semi-useful "power" reading after two pulses, instead of a useless single "impulse" reading.)
but this breaks the unit-test, because mock_MeterS0 links MeterS0.cpp without also linking Config_Options.cpp. options should probably be replaced with a mock for that purpose, but it's not so straightforard for me,
can you provide at least a pointer to how you would handle this?
(alternatively one could write code to feed the single-shot flag into MeterS0 when constructing/configuring it,
but adding such meter-specific code to the nice generic meter-interface
doesn't seem better to me than accessing the global from the meter.)
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
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.
WIP: fix #389