TEST_P(RedirectIntegrationTest, UpstreamRedirectPreservesURIFragmentInLocation) {
  // Use base class initialize.
  HttpProtocolIntegrationTest::initialize();

  codec_client_ = makeHttpConnection(lookupPort("http"));
  Http::TestResponseHeaderMapImpl redirect_response{
      {":status", "302"},
      {"content-length", "0"},
      {"location", "http://authority2/new/url?p1=v1&p2=v2#fragment"}};
  auto response = sendRequestAndWaitForResponse(default_request_headers_, 0, redirect_response, 0);
  EXPECT_TRUE(response->complete());
  EXPECT_EQ("302", response->headers().getStatusValue());
  EXPECT_EQ("http://authority2/new/url?p1=v1&p2=v2#fragment",
            response->headers().getLocationValue());
}
TEST_P(RedirectIntegrationTest, UpstreamRedirectPreservesURIFragmentInLocation) {
   
  HttpProtocolIntegrationTest::initialize();

  codec_client_ = makeHttpConnection(lookupPort("http"));
  Http::TestResponseHeaderMapImpl redirect_response{
      {":status", "302"},
      {"content-length", "0"},
      {"location", "http://authority2/new/url?p1=v1&p2=v2#fragment"}};
  auto response = sendRequestAndWaitForResponse(default_request_headers_, 0, redirect_response, 0);
  EXPECT_TRUE(response->complete());
  EXPECT_EQ("302", response->headers().getStatusValue());
  EXPECT_EQ("http://authority2/new/url?p1=v1&p2=v2#fragment",
            response->headers().getLocationValue());
}