| 471 | } // namespace |
| 472 | |
| 473 | TEST(RleBitPackedToBitmapDecoder, Empty) { |
| 474 | // A default-constructed decoder is already exhausted. |
| 475 | RleBitPackedToBitmapDecoder decoder; |
| 476 | EXPECT_TRUE(decoder.exhausted()); |
| 477 | uint8_t out = 0; |
| 478 | auto got = decoder.GetBatch(BitmapSpanMut(&out), 8); |
| 479 | EXPECT_EQ(got, 0); |
| 480 | |
| 481 | // So is one reset on an empty buffer. |
| 482 | decoder.Reset(nullptr, 0); |
| 483 | EXPECT_TRUE(decoder.exhausted()); |
| 484 | got = decoder.GetBatch(BitmapSpanMut(&out), 8); |
| 485 | EXPECT_EQ(got, 0); |
| 486 | } |
| 487 | |
| 488 | TEST(RleBitPackedToBitmapDecoder, SingleRleZeros) { |
| 489 | std::vector<uint8_t> bytes; |
nothing calls this directly
no test coverage detected