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

Unified Diff: chrome/browser/net/connection_tester_unittest.cc

Issue 10909245: Places that create a CookieMonster should also create a ServerBoundCertService. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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 | « chrome/browser/net/connection_tester.cc ('k') | chrome/service/net/service_url_request_context.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/net/connection_tester_unittest.cc
diff --git a/chrome/browser/net/connection_tester_unittest.cc b/chrome/browser/net/connection_tester_unittest.cc
index 7371a29d87d7e83ae7d022fc6d4c4a64b5ad44c6..8598cf31492e9b0fbf914ef5a64d557ee1b487df 100644
--- a/chrome/browser/net/connection_tester_unittest.cc
+++ b/chrome/browser/net/connection_tester_unittest.cc
@@ -4,10 +4,13 @@
#include "chrome/browser/net/connection_tester.h"
+#include "base/threading/worker_pool.h"
#include "chrome/test/base/testing_pref_service.h"
#include "content/public/test/test_browser_thread.h"
+#include "net/base/default_server_bound_cert_store.h"
#include "net/base/mock_cert_verifier.h"
#include "net/base/mock_host_resolver.h"
+#include "net/base/server_bound_cert_service.h"
#include "net/base/ssl_config_service_defaults.h"
#include "net/cookies/cookie_monster.h"
#include "net/ftp/ftp_network_layer.h"
@@ -115,6 +118,7 @@ class ConnectionTesterTest : public PlatformTest {
net::HttpAuthHandlerRegistryFactory http_auth_handler_factory_;
net::HttpServerPropertiesImpl http_server_properties_impl_;
scoped_ptr<net::URLRequestContext> proxy_script_fetcher_context_;
+ scoped_ptr<net::ServerBoundCertService> server_bound_cert_service_;
private:
void InitializeRequestContext() {
@@ -125,10 +129,16 @@ class ConnectionTesterTest : public PlatformTest {
&http_auth_handler_factory_);
proxy_service_.reset(net::ProxyService::CreateDirect());
proxy_script_fetcher_context_->set_proxy_service(proxy_service_.get());
+ // In-memory server bound cert service.
+ server_bound_cert_service_.reset(new net::ServerBoundCertService(
+ new net::DefaultServerBoundCertStore(NULL),
+ base::WorkerPool::GetTaskRunner(true)));
+
ssl_config_service_ = new net::SSLConfigServiceDefaults;
net::HttpNetworkSession::Params session_params;
session_params.host_resolver = &host_resolver_;
session_params.cert_verifier = cert_verifier_.get();
+ session_params.server_bound_cert_service = server_bound_cert_service_.get();
session_params.http_auth_handler_factory = &http_auth_handler_factory_;
session_params.ssl_config_service = ssl_config_service_;
session_params.proxy_service = proxy_service_.get();
« no previous file with comments | « chrome/browser/net/connection_tester.cc ('k') | chrome/service/net/service_url_request_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698