use of org.webpieces.httpparser.api.dto.HttpLastChunk in project webpieces by deanhiller.
the class TestGooglePlayback method testGooglePlayback.
@Test
public void testGooglePlayback() {
List<HttpPayload> results = runPlayback("google.com.11015.recording");
Assert.assertEquals(3, results.size());
HttpResponse resp = (HttpResponse) results.get(0);
HttpChunk chunk = (HttpChunk) results.get(1);
HttpLastChunk lastChunk = (HttpLastChunk) results.get(2);
Assert.assertEquals("chunked", resp.getHeaderLookupStruct().getHeader(KnownHeaderName.TRANSFER_ENCODING).getValue());
Assert.assertEquals(10349, chunk.getBody().getReadableSize());
Assert.assertTrue(lastChunk.isEndOfData());
}
Aggregations