@Test
public void testCustomData() {

    PerMessageDeflateClientExtensionHandshaker handshaker =
            new PerMessageDeflateClientExtensionHandshaker(6, true, 10, true, true);
    WebSocketExtensionData data = handshaker.newRequestData();
    assertEquals(PERMESSAGE_DEFLATE_EXTENSION, data.name());
    assertTrue(data.parameters().containsKey(CLIENT_MAX_WINDOW));
    assertTrue(data.parameters().containsKey(SERVER_MAX_WINDOW));
    assertEquals("10", data.parameters().get(SERVER_MAX_WINDOW));
    assertTrue(data.parameters().containsKey(CLIENT_MAX_WINDOW));
    assertTrue(data.parameters().containsKey(SERVER_MAX_WINDOW));
}