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

Unified Diff: net/quic/quic_network_transaction_unittest.cc

Issue 1216703002: Implement multiple alternative services per origin. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nit. Created 5 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_stream_factory_impl.cc ('k') | net/quic/quic_stream_factory.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_network_transaction_unittest.cc
diff --git a/net/quic/quic_network_transaction_unittest.cc b/net/quic/quic_network_transaction_unittest.cc
index 0720f8b60da334d468d00cf772bacebce2d4bbc9..8477ab06f4ed11774239d11469e37dccb92619c0 100644
--- a/net/quic/quic_network_transaction_unittest.cc
+++ b/net/quic/quic_network_transaction_unittest.cc
@@ -331,18 +331,19 @@ class QuicNetworkTransactionTest
void ExpectBrokenAlternateProtocolMapping() {
const HostPortPair origin = HostPortPair::FromURL(request_.url);
- const AlternativeService alternative_service =
- http_server_properties_.GetAlternativeService(origin);
- EXPECT_NE(UNINITIALIZED_ALTERNATE_PROTOCOL, alternative_service.protocol);
+ const AlternativeServiceVector alternative_service_vector =
+ http_server_properties_.GetAlternativeServices(origin);
+ EXPECT_EQ(1u, alternative_service_vector.size());
EXPECT_TRUE(http_server_properties_.IsAlternativeServiceBroken(
- alternative_service));
+ alternative_service_vector[0]));
}
void ExpectQuicAlternateProtocolMapping() {
- const AlternativeService alternative_service =
- http_server_properties_.GetAlternativeService(
- HostPortPair::FromURL(request_.url));
- EXPECT_EQ(QUIC, alternative_service.protocol);
+ const HostPortPair origin = HostPortPair::FromURL(request_.url);
+ const AlternativeServiceVector alternative_service_vector =
+ http_server_properties_.GetAlternativeServices(origin);
+ EXPECT_EQ(1u, alternative_service_vector.size());
+ EXPECT_EQ(QUIC, alternative_service_vector[0].protocol);
}
void AddHangingNonAlternateProtocolSocketData() {
« no previous file with comments | « net/http/http_stream_factory_impl.cc ('k') | net/quic/quic_stream_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698