| 22 | class HdrHistogramTest : public testing::Test {}; |
| 23 | |
| 24 | TEST_F(HdrHistogramTest, HistogramTotalSum) { |
| 25 | constexpr uint64_t MAX_VALUE = 10000; |
| 26 | HdrHistogram* histogram = new HdrHistogram(MAX_VALUE, 3); |
| 27 | |
| 28 | histogram->Increment(100); |
| 29 | histogram->IncrementBy(10, 50); |
| 30 | EXPECT_EQ(histogram->TotalSum(), 600); |
| 31 | |
| 32 | histogram->Increment(24000); |
| 33 | EXPECT_EQ(histogram->TotalSum(), 24600); |
| 34 | } |
| 35 | |
| 36 | TEST_F(HdrHistogramTest, HistogramTotalSumIsMovedToNewHdrHistogram) { |
| 37 | constexpr uint64_t MAX_VALUE = 10000; |
nothing calls this directly
no test coverage detected