@Test
public void testMaximumChunks() throws IOException {

    final ResponseOutOfOrderStrategy strategy = new MonitoringResponseOutOfOrderStrategy(1, 2);
    Assert.assertTrue(strategy.isEarlyResponseDetected(
            REQUEST,
            connection(true, true),
            socketInputStream(0),
            0,
            1));
    Assert.assertTrue(strategy.isEarlyResponseDetected(
            REQUEST,
            connection(true, true),
            socketInputStream(0),
            1,
            2));
    Assert.assertFalse(strategy.isEarlyResponseDetected(
            REQUEST,
            connection(true, true),
            socketInputStream(0),
            2,
            3));
}