| 31 | namespace { |
| 32 | #if !WITH_BABYLON_COUNTER |
| 33 | TEST(RecorderTest, test_complement) { |
| 34 | LOG(INFO) << "sizeof(LatencyRecorder)=" << sizeof(bvar::LatencyRecorder) |
| 35 | << " " << sizeof(bvar::detail::Percentile) |
| 36 | << " " << sizeof(bvar::Maxer<int64_t>) |
| 37 | << " " << sizeof(bvar::IntRecorder) |
| 38 | << " " << sizeof(bvar::Window<bvar::IntRecorder>) |
| 39 | << " " << sizeof(bvar::Window<bvar::detail::Percentile>); |
| 40 | |
| 41 | for (int a = -10000000; a < 10000000; ++a) { |
| 42 | const uint64_t complement = bvar::IntRecorder::_get_complement(a); |
| 43 | const int64_t b = bvar::IntRecorder::_extend_sign_bit(complement); |
| 44 | ASSERT_EQ(a, b); |
| 45 | } |
| 46 | } |
| 47 | |
| 48 | TEST(RecorderTest, test_compress) { |
| 49 | const uint64_t num = 125345; |
nothing calls this directly
no test coverage detected