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

Side by Side Diff: base/metrics/histogram_unittest.cc

Issue 10703037: Move StatisticsRecorder out of histogram.cc/h for further refactoring. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 | « base/metrics/histogram_snapshot_manager.cc ('k') | base/metrics/statistics_recorder.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // Test of Histogram class 5 // Test of Histogram class
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/logging.h"
10 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
11 #include "base/metrics/histogram.h" 12 #include "base/metrics/histogram.h"
13 #include "base/metrics/statistics_recorder.h"
12 #include "base/time.h" 14 #include "base/time.h"
13 #include "testing/gtest/include/gtest/gtest.h" 15 #include "testing/gtest/include/gtest/gtest.h"
14 16
15 namespace base { 17 namespace base {
16 namespace { 18 namespace {
17 19
18 class HistogramTest : public testing::Test { 20 class HistogramTest : public testing::Test {
19 }; 21 };
20 22
21 // Check for basic syntax and use. 23 // Check for basic syntax and use.
(...skipping 422 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 "Histogram3", 1, 64, 16, Histogram::kNoFlags)); 446 "Histogram3", 1, 64, 16, Histogram::kNoFlags));
445 447
446 CachedRanges* cached_ranges1 = histogram1->cached_ranges(); 448 CachedRanges* cached_ranges1 = histogram1->cached_ranges();
447 CachedRanges* cached_ranges2 = histogram2->cached_ranges(); 449 CachedRanges* cached_ranges2 = histogram2->cached_ranges();
448 CachedRanges* cached_ranges3 = histogram3->cached_ranges(); 450 CachedRanges* cached_ranges3 = histogram3->cached_ranges();
449 EXPECT_TRUE(cached_ranges1->Equals(cached_ranges2)); 451 EXPECT_TRUE(cached_ranges1->Equals(cached_ranges2));
450 EXPECT_FALSE(cached_ranges1->Equals(cached_ranges3)); 452 EXPECT_FALSE(cached_ranges1->Equals(cached_ranges3));
451 } 453 }
452 454
453 } // namespace base 455 } // namespace base
OLDNEW
« no previous file with comments | « base/metrics/histogram_snapshot_manager.cc ('k') | base/metrics/statistics_recorder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698