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

Side by Side Diff: net/socket_stream/socket_stream_metrics_unittest.cc

Issue 6362186595172352: net: Migrate from googleurl/ includes to url/ ones. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase and revert nss_ocsp.cc changes Created 7 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
« no previous file with comments | « net/socket_stream/socket_stream_metrics.cc ('k') | net/spdy/spdy_credential_state.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "net/socket_stream/socket_stream_metrics.h" 5 #include "net/socket_stream/socket_stream_metrics.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/metrics/histogram_samples.h" 10 #include "base/metrics/histogram_samples.h"
11 #include "base/metrics/statistics_recorder.h" 11 #include "base/metrics/statistics_recorder.h"
12 #include "googleurl/src/gurl.h"
13 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
14 #include "testing/platform_test.h" 13 #include "testing/platform_test.h"
14 #include "url/gurl.h"
15 15
16 using base::Histogram; 16 using base::Histogram;
17 using base::HistogramBase; 17 using base::HistogramBase;
18 using base::HistogramSamples; 18 using base::HistogramSamples;
19 using base::StatisticsRecorder; 19 using base::StatisticsRecorder;
20 20
21 namespace net { 21 namespace net {
22 22
23 TEST(SocketStreamMetricsTest, ProtocolType) { 23 TEST(SocketStreamMetricsTest, ProtocolType) {
24 // First we'll preserve the original values. We need to do this 24 // First we'll preserve the original values. We need to do this
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 // SentCounts. 212 // SentCounts.
213 histogram = 213 histogram =
214 StatisticsRecorder::FindHistogram("Net.SocketStream.SentCounts"); 214 StatisticsRecorder::FindHistogram("Net.SocketStream.SentCounts");
215 ASSERT_TRUE(histogram != NULL); 215 ASSERT_TRUE(histogram != NULL);
216 EXPECT_EQ(HistogramBase::kUmaTargetedHistogramFlag, histogram->flags()); 216 EXPECT_EQ(HistogramBase::kUmaTargetedHistogramFlag, histogram->flags());
217 samples = histogram->SnapshotSamples(); 217 samples = histogram->SnapshotSamples();
218 EXPECT_EQ(3, samples->sum() - original_sent_counts); // 3 write requests. 218 EXPECT_EQ(3, samples->sum() - original_sent_counts); // 3 write requests.
219 } 219 }
220 220
221 } // namespace net 221 } // namespace net
OLDNEW
« no previous file with comments | « net/socket_stream/socket_stream_metrics.cc ('k') | net/spdy/spdy_credential_state.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698