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

Side by Side Diff: chrome/browser/net/http_pipelining_compatibility_client_unittest.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 years, 8 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/net/http_pipelining_compatibility_client.h" 5 #include "chrome/browser/net/http_pipelining_compatibility_client.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 BrowserThread::ReleaseSoon(BrowserThread::IO, FROM_HERE, context_); 111 BrowserThread::ReleaseSoon(BrowserThread::IO, FROM_HERE, context_);
112 message_loop_.RunUntilIdle(); 112 message_loop_.RunUntilIdle();
113 STLDeleteValues(&original_samples_); 113 STLDeleteValues(&original_samples_);
114 } 114 }
115 115
116 void RunTest( 116 void RunTest(
117 std::vector<RequestInfo> requests, 117 std::vector<RequestInfo> requests,
118 HttpPipeliningCompatibilityClient::Options options) { 118 HttpPipeliningCompatibilityClient::Options options) {
119 HttpPipeliningCompatibilityClient client(NULL); 119 HttpPipeliningCompatibilityClient client(NULL);
120 net::TestCompletionCallback callback; 120 net::TestCompletionCallback callback;
121 client.Start(test_server_.GetURL("").spec(), 121 client.Start(test_server_.GetURL(std::string()).spec(),
122 requests, options, callback.callback(), 122 requests,
123 options,
124 callback.callback(),
123 context_->GetURLRequestContext()); 125 context_->GetURLRequestContext());
124 callback.WaitForResult(); 126 callback.WaitForResult();
125 } 127 }
126 128
127 void ExpectHistogramCount(int expected_count, 129 void ExpectHistogramCount(int expected_count,
128 int expected_value, 130 int expected_value,
129 HistogramField field) { 131 HistogramField field) {
130 const char* name; 132 const char* name;
131 133
132 switch (field) { 134 switch (field) {
(...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after
586 callback.WaitForResult(); 588 callback.WaitForResult();
587 589
588 ExpectHistogramCount(1, false, FIELD_CANARY); 590 ExpectHistogramCount(1, false, FIELD_CANARY);
589 ExpectHistogramCount(0, false, FIELD_SUCCESS); 591 ExpectHistogramCount(0, false, FIELD_SUCCESS);
590 ExpectHistogramCount(0, true, FIELD_SUCCESS); 592 ExpectHistogramCount(0, true, FIELD_SUCCESS);
591 } 593 }
592 594
593 } // anonymous namespace 595 } // anonymous namespace
594 596
595 } // namespace chrome_browser_net 597 } // namespace chrome_browser_net
OLDNEW
« no previous file with comments | « chrome/browser/net/dns_probe_job_unittest.cc ('k') | chrome/browser/net/pref_proxy_config_tracker_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698