@Test
public void names() {

    ReadOnlyHttpHeaders headers = new ReadOnlyHttpHeaders(true,
            ACCEPT, APPLICATION_JSON, CONTENT_LENGTH, ZERO, CONNECTION, CLOSE);
    assertFalse(headers.isEmpty());
    assertEquals(3, headers.size());
    Set<String> names = headers.names();
    assertEquals(3, names.size());
    assertTrue(names.contains(ACCEPT.toString()));
    assertTrue(names.contains(CONTENT_LENGTH.toString()));
    assertTrue(names.contains(CONNECTION.toString()));
}