mirror of
https://github.com/XRPLF/rippled.git
synced 2026-09-28 15:58:07 +00:00
The metric macros discard their arguments when telemetry is compiled out, so anything named only as a macro argument disappears in that build. That produced fifteen errors across these files. - guard MetricNames.h in the nine files whose only uses of it are macro arguments; the files that pass those constants as ordinary function arguments still need it unconditionally - drop the prevMode local in setMode, reading the mode being left inline in the macro argument so nothing is computed when telemetry is off - compile out the emit helper in recordBatchOutcome and its three calls, which exist only to report per-outcome counters - drop two includes the telemetry-off test block never used - suppress the static and const suggestions on four methods whose bodies only record metrics; each reads the app_ member when telemetry is enabled
Unit tests
This directory contains unit tests for the project. The difference from existing src/test folder
is that we switch to 3rd party testing framework (gtest). We intend to gradually move existing tests
from our own framework to gtest and such tests will be moved to this new folder.