Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(715)

Unified Diff: net/http/http_network_transaction_unittest.cc

Issue 377063002: Revert of Add a probability to Alternate-Protocol support. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/http/http_network_transaction.cc ('k') | net/http/http_server_properties.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_network_transaction_unittest.cc
diff --git a/net/http/http_network_transaction_unittest.cc b/net/http/http_network_transaction_unittest.cc
index 8c078c4c1f158797ad4d8715d780b02e902750ca..ab64040df1ab4b3619e28f2bb584e17c1abd9688 100644
--- a/net/http/http_network_transaction_unittest.cc
+++ b/net/http/http_network_transaction_unittest.cc
@@ -7536,7 +7536,7 @@
session->http_server_properties();
http_server_properties->SetAlternateProtocol(
HostPortPair("host.with.alternate", 80), 443,
- AlternateProtocolFromNextProto(next_proto), 1);
+ AlternateProtocolFromNextProto(next_proto));
return session;
}
@@ -8448,10 +8448,11 @@
EXPECT_EQ("hello world", response_data);
ASSERT_TRUE(http_server_properties.HasAlternateProtocol(http_host_port_pair));
- const AlternateProtocolInfo alternate =
+ const PortAlternateProtocolPair alternate =
http_server_properties.GetAlternateProtocol(http_host_port_pair);
- AlternateProtocolInfo expected_alternate(
- 443, AlternateProtocolFromNextProto(GetParam()), 1);
+ PortAlternateProtocolPair expected_alternate;
+ expected_alternate.port = 443;
+ expected_alternate.protocol = AlternateProtocolFromNextProto(GetParam());
EXPECT_TRUE(expected_alternate.Equals(alternate));
}
@@ -8487,7 +8488,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(request.url),
666 /* port is ignored by MockConnect anyway */,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -8508,7 +8509,7 @@
ASSERT_TRUE(http_server_properties->HasAlternateProtocol(
HostPortPair::FromURL(request.url)));
- const AlternateProtocolInfo alternate =
+ const PortAlternateProtocolPair alternate =
http_server_properties->GetAlternateProtocol(
HostPortPair::FromURL(request.url));
EXPECT_EQ(ALTERNATE_PROTOCOL_BROKEN, alternate.protocol);
@@ -8549,7 +8550,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(restricted_port_request.url),
kUnrestrictedAlternatePort,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -8600,7 +8601,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(restricted_port_request.url),
kUnrestrictedAlternatePort,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -8648,7 +8649,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(restricted_port_request.url),
kRestrictedAlternatePort,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -8697,7 +8698,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(unrestricted_port_request.url),
kRestrictedAlternatePort,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -8745,7 +8746,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(unrestricted_port_request.url),
kUnrestrictedAlternatePort,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -8788,7 +8789,7 @@
http_server_properties->SetAlternateProtocol(
HostPortPair::FromURL(request.url),
kUnsafePort,
- AlternateProtocolFromNextProto(GetParam()), 1);
+ AlternateProtocolFromNextProto(GetParam()));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
« no previous file with comments | « net/http/http_network_transaction.cc ('k') | net/http/http_server_properties.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698