Lines Matching refs:HeaderKeyValuePair
42 typedef std::pair<std::string, std::string> HeaderKeyValuePair;
44 std::vector<HeaderKeyValuePair> ToVector(const HttpRequestHeaders& headers) {
46 std::vector<HeaderKeyValuePair> result;
48 result.push_back(HeaderKeyValuePair(it.name(), it.value()));
52 std::vector<HeaderKeyValuePair> ToVector(const HttpResponseHeaders& headers) {
55 std::vector<HeaderKeyValuePair> result;
57 result.push_back(HeaderKeyValuePair(name, value));
459 std::vector<HeaderKeyValuePair> request_headers =
468 EXPECT_EQ(HeaderKeyValuePair("Host", "localhost"), request_headers[0]);
469 EXPECT_EQ(HeaderKeyValuePair("Connection", "Upgrade"), request_headers[1]);
470 EXPECT_EQ(HeaderKeyValuePair("Pragma", "no-cache"), request_headers[2]);
471 EXPECT_EQ(HeaderKeyValuePair("Cache-Control", "no-cache"),
473 EXPECT_EQ(HeaderKeyValuePair("Upgrade", "websocket"), request_headers[4]);
474 EXPECT_EQ(HeaderKeyValuePair("Origin", "http://localhost"),
476 EXPECT_EQ(HeaderKeyValuePair("Sec-WebSocket-Version", "13"),
478 EXPECT_EQ(HeaderKeyValuePair("User-Agent", ""), request_headers[7]);
479 EXPECT_EQ(HeaderKeyValuePair("Accept-Encoding", "gzip, deflate"),
481 EXPECT_EQ(HeaderKeyValuePair("Accept-Language", "en-us,fr"),
484 EXPECT_EQ(HeaderKeyValuePair("Sec-WebSocket-Extensions",
488 std::vector<HeaderKeyValuePair> response_headers =
494 EXPECT_EQ(HeaderKeyValuePair("Connection", "Upgrade"), response_headers[0]);
496 EXPECT_EQ(HeaderKeyValuePair("Upgrade", "websocket"), response_headers[2]);
497 EXPECT_EQ(HeaderKeyValuePair("foo", "bar, baz"), response_headers[3]);
498 EXPECT_EQ(HeaderKeyValuePair("hoge", "fuga"), response_headers[4]);
499 EXPECT_EQ(HeaderKeyValuePair("hoge", "piyo"), response_headers[5]);