| 94 | } |
| 95 | |
| 96 | void AssertWholeObjects(Chunker& chunker, const std::shared_ptr<Buffer>& block, |
| 97 | int expected_count) { |
| 98 | std::shared_ptr<Buffer> whole, partial; |
| 99 | ASSERT_OK(chunker.Process(block, &whole, &partial)); |
| 100 | int count; |
| 101 | AssertOnlyWholeObjects(chunker, whole, &count); |
| 102 | ASSERT_EQ(count, expected_count); |
| 103 | } |
| 104 | |
| 105 | void AssertChunking(Chunker& chunker, std::shared_ptr<Buffer> buf, int total_count) { |
| 106 | // First chunkize whole JSON block |
no test coverage detected