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

Side by Side Diff: chrome_frame/test/test_server_test.cc

Issue 3019007: Add a command line flag to change the default number of parallel DNS requests... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Address jar's comments Created 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <windows.h> 5 #include <windows.h>
6 #include <wininet.h> 6 #include <wininet.h>
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/scoped_handle_win.h" 10 #include "base/scoped_handle_win.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 return h_; 54 return h_;
55 } 55 }
56 56
57 protected: 57 protected:
58 HINTERNET h_; 58 HINTERNET h_;
59 }; 59 };
60 60
61 class URLRequestTestContext : public URLRequestContext { 61 class URLRequestTestContext : public URLRequestContext {
62 public: 62 public:
63 URLRequestTestContext() { 63 URLRequestTestContext() {
64 host_resolver_ = net::CreateSystemHostResolver(); 64 host_resolver_ =
65 net::CreateSystemHostResolver(net::HostResolver::kDefaultParallelism);
65 proxy_service_ = net::ProxyService::CreateNull(); 66 proxy_service_ = net::ProxyService::CreateNull();
66 ssl_config_service_ = new net::SSLConfigServiceDefaults; 67 ssl_config_service_ = new net::SSLConfigServiceDefaults;
67 http_auth_handler_factory_ = net::HttpAuthHandlerFactory::CreateDefault(); 68 http_auth_handler_factory_ = net::HttpAuthHandlerFactory::CreateDefault();
68 http_transaction_factory_ = new net::HttpCache( 69 http_transaction_factory_ = new net::HttpCache(
69 net::HttpNetworkLayer::CreateFactory(host_resolver_, proxy_service_, 70 net::HttpNetworkLayer::CreateFactory(host_resolver_, proxy_service_,
70 ssl_config_service_, http_auth_handler_factory_, NULL, NULL), 71 ssl_config_service_, http_auth_handler_factory_, NULL, NULL),
71 net::HttpCache::DefaultBackend::InMemory(0)); 72 net::HttpCache::DefaultBackend::InMemory(0));
72 // In-memory cookie store. 73 // In-memory cookie store.
73 cookie_store_ = new net::CookieMonster(NULL, NULL); 74 cookie_store_ = new net::CookieMonster(NULL, NULL);
74 } 75 }
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 EXPECT_EQ(file.accessed(), 1); 188 EXPECT_EQ(file.accessed(), 1);
188 EXPECT_EQ(redir.accessed(), 1); 189 EXPECT_EQ(redir.accessed(), 1);
189 190
190 EXPECT_TRUE(person_task.response().find("Guthrie") != std::string::npos); 191 EXPECT_TRUE(person_task.response().find("Guthrie") != std::string::npos);
191 EXPECT_TRUE(file_task.response().find("function") != std::string::npos); 192 EXPECT_TRUE(file_task.response().find("function") != std::string::npos);
192 EXPECT_TRUE(goog_task.response().find("<title>") != std::string::npos); 193 EXPECT_TRUE(goog_task.response().find("<title>") != std::string::npos);
193 } else { 194 } else {
194 ::TerminateThread(worker, ~0); 195 ::TerminateThread(worker, ~0);
195 } 196 }
196 } 197 }
OLDNEW
« no previous file with comments | « chrome/service/net/service_url_request_context.cc ('k') | jingle/notifier/listener/mediator_thread_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698