    @Test
    public void testSet() {

        HttpHeaders headers = new HttpHeaders(2);
        headers.set("Connection", "close");
        headers.set("Connection", "Keep-Alive");
        headers.set("Accept-Encoding", "gzip, deflate");

        Assert.assertEquals("Keep-Alive", headers.get("Connection"));
        Assert.assertEquals("gzip, deflate", headers.get("Accept-Encoding"));

        Assert.assertEquals(Collections.singletonList("Keep-Alive"), headers.getValues("Connection"));
        Assert.assertEquals(Collections.singletonList("gzip, deflate"), headers.getValues("Accept-Encoding"));
    }