use of com.google.api.gax.rpc.Batch.BatchByteCounter in project gax-java by googleapis.
the class BatchTest method testBatchByteCounter.
@Test
public void testBatchByteCounter() {
ElementCounter<Batch<LabeledIntList, List<Integer>>> counter = new BatchByteCounter<>();
LabeledIntList request = new LabeledIntList("lable", 3);
Batch<LabeledIntList, List<Integer>> batch = createBatch(request);
Truth.assertThat(counter.count(batch)).isEqualTo(3);
}
Aggregations