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

Unified Diff: components/cronet/url_request_context_config_unittest.cc

Issue 1507253003: [Cronet] Allow experimenting with Chrome's internal DNS resolver. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@nojson3
Patch Set: address nits Created 5 years 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 | « components/cronet/url_request_context_config.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/cronet/url_request_context_config_unittest.cc
diff --git a/components/cronet/url_request_context_config_unittest.cc b/components/cronet/url_request_context_config_unittest.cc
index bb88ec2c78c31df1961f0e22bb73254ae443834d..24bbfaa61ba200f4b30c6d79fe7179dbf4cdad5b 100644
--- a/components/cronet/url_request_context_config_unittest.cc
+++ b/components/cronet/url_request_context_config_unittest.cc
@@ -38,7 +38,8 @@ TEST(URLRequestContextConfigTest, SetQuicExperimentalOptions) {
"\"delay_tcp_race\":true,"
"\"max_number_of_lossy_connections\":10,"
"\"packet_loss_threshold\":0.5,"
- "\"connection_options\":\"TIME,TBBR,REJ\"}}",
+ "\"connection_options\":\"TIME,TBBR,REJ\"},"
+ "\"AsyncDNS\":{\"enable\":true}}",
// Data reduction proxy key.
"",
// Data reduction proxy.
@@ -51,7 +52,8 @@ TEST(URLRequestContextConfigTest, SetQuicExperimentalOptions) {
scoped_ptr<net::CertVerifier>());
net::URLRequestContextBuilder builder;
- config.ConfigureURLRequestContextBuilder(&builder);
+ net::NetLog net_log;
+ config.ConfigureURLRequestContextBuilder(&builder, &net_log);
// Set a ProxyConfigService to avoid DCHECK failure when building.
builder.set_proxy_config_service(make_scoped_ptr(
new net::ProxyConfigServiceFixed(net::ProxyConfig::CreateDirect())));
@@ -74,6 +76,9 @@ TEST(URLRequestContextConfigTest, SetQuicExperimentalOptions) {
// Check max_number_of_lossy_connections and packet_loss_threshold.
EXPECT_EQ(10, params->quic_max_number_of_lossy_connections);
EXPECT_FLOAT_EQ(0.5f, params->quic_packet_loss_threshold);
+
+ // Check AsyncDNS resolver is enabled.
+ EXPECT_NE(nullptr, context->host_resolver()->GetDnsConfigAsValue());
}
} // namespace cronet
« no previous file with comments | « components/cronet/url_request_context_config.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698