### Question:
HeaderUtils { public static boolean isTransferEncodingChunked(final HttpHeaders headers) { return containsCommaSeparatedValueIgnoreCase(headers, TRANSFER_ENCODING, CHUNKED); } private  HeaderUtils(); static boolean isTransferEncodingChunked(final HttpHeaders headers); static boolean domainMatches(final CharSequence requestDomain, @Nullable final CharSequence cookieDomain); static boolean pathMatches(final CharSequence requestPath, @Nullable final CharSequence cookiePath); static boolean isSetCookieNameMatches(final CharSequence setCookieString,
                                                 final CharSequence setCookieName); @Nullable static HttpSetCookie parseSetCookie(final CharSequence setCookieString,
                                               final CharSequence setCookieName,
                                               final boolean validate); @Nullable static HttpCookiePair parseCookiePair(final CharSequence cookieString,
                                                 final CharSequence cookiePairName); @Nullable static CharSequence removeCookiePairs(final CharSequence cookieString,
                                                 final CharSequence cookiePairName); static boolean hasContentType(final HttpHeaders headers,
                                         final CharSequence expectedContentType,
                                         @Nullable final Charset expectedCharset); static final BiFunction<? super CharSequence, ? super CharSequence, CharSequence> DEFAULT_HEADER_FILTER; }### Answer:
@Test public void isTransferEncodingChunkedFalseCases() { HttpHeaders headers = DefaultHttpHeadersFactory.INSTANCE.newHeaders(); assertTrue(headers.isEmpty()); assertFalse(isTransferEncodingChunked(headers)); headers.add("Some-Header", "Some-Value"); assertFalse(isTransferEncodingChunked(headers)); headers.add(TRANSFER_ENCODING, "Some-Value"); assertFalse(isTransferEncodingChunked(headers)); assertFalse(isTransferEncodingChunked(headersWithTransferEncoding(of("gzip")) .add(TRANSFER_ENCODING, "base64"))); }
@Test public void isTransferEncodingChunkedTrueCases() { HttpHeaders headers = DefaultHttpHeadersFactory.INSTANCE.newHeaders(); assertTrue(headers.isEmpty()); headers.set(TRANSFER_ENCODING, CHUNKED); assertOneTransferEncodingChunked(headers); headers.set("Transfer-Encoding", "Chunked"); assertOneTransferEncodingChunked(headers); headers.set(TRANSFER_ENCODING, "cHuNkEd"); assertOneTransferEncodingChunked(headers); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("chunked,gzip")))); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("chunked, gzip")))); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("gzip, chunked")))); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("gzip,chunked")))); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("gzip, chunked, base64")))); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("gzip")) .add(TRANSFER_ENCODING, "chunked"))); assertTrue(isTransferEncodingChunked(headersWithTransferEncoding(of("chunked")) .add(TRANSFER_ENCODING, "gzip"))); }