private void compareCookies(Set<Cookie> expected, Set<javax.servlet.http.Cookie> actual) {
    Assert.assertEquals("Size didn't match", expected.size(), actual.size());
    HashMap<String, Cookie> expectedHashMap = new HashMap<String, Cookie>();
    for (Cookie cookie : expected) {
      expectedHashMap.put(cookie.name(), cookie);
    }
    for (javax.servlet.http.Cookie cookie : actual) {
      Assert.assertEquals("Value field didn't match ", expectedHashMap.get(cookie.getName()).value(),
          cookie.getValue());
    }
  }
Compares a set of HttpCookies {@link Cookie} with a set of Java Cookies {@link javax.servlet.http.Cookie} for
equality in values
@param expected Set of {@link Cookie}s to be compared with the {@code actual}
@param actual Set of {@link javax.servlet.http.Cookie}s to be compared with those of {@code expected}
ambry-rest/src/test/java/com/github/ambry/rest/NettyRequestTest.java