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

Side by Side Diff: chrome/browser/chromeos/external_metrics_unittest.cc

Issue 394093003: Moves components/metrics/chromeos to c/m/serialization/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: added os=="linux" GYP guards Created 6 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
« no previous file with comments | « chrome/browser/chromeos/external_metrics.cc ('k') | components/components_tests.gyp » ('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 "base/file_util.h" 5 #include "base/file_util.h"
6 #include "base/files/scoped_temp_dir.h" 6 #include "base/files/scoped_temp_dir.h"
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "base/metrics/statistics_recorder.h" 8 #include "base/metrics/statistics_recorder.h"
9 #include "chrome/browser/chromeos/external_metrics.h" 9 #include "chrome/browser/chromeos/external_metrics.h"
10 #include "chrome/test/base/uma_histogram_helper.h" 10 #include "chrome/test/base/uma_histogram_helper.h"
11 #include "components/metrics/chromeos/metric_sample.h" 11 #include "components/metrics/serialization/metric_sample.h"
12 #include "components/metrics/chromeos/serialization_utils.h" 12 #include "components/metrics/serialization/serialization_utils.h"
13 #include "content/public/test/test_browser_thread_bundle.h" 13 #include "content/public/test/test_browser_thread_bundle.h"
14 14
15 namespace chromeos { // Need this because of the FRIEND_TEST 15 namespace chromeos { // Need this because of the FRIEND_TEST
16 16
17 class ExternalMetricsTest : public testing::Test { 17 class ExternalMetricsTest : public testing::Test {
18 public: 18 public:
19 virtual void SetUp() OVERRIDE { 19 virtual void SetUp() OVERRIDE {
20 ASSERT_TRUE(dir_.CreateUniqueTempDir()); 20 ASSERT_TRUE(dir_.CreateUniqueTempDir());
21 external_metrics_ = ExternalMetrics::CreateForTesting( 21 external_metrics_ = ExternalMetrics::CreateForTesting(
22 dir_.path().Append("testfile").value()); 22 dir_.path().Append("testfile").value());
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 *hist.get(), external_metrics_->uma_events_file_)); 59 *hist.get(), external_metrics_->uma_events_file_));
60 60
61 external_metrics_->CollectEvents(); 61 external_metrics_->CollectEvents();
62 62
63 UMAHistogramHelper helper; 63 UMAHistogramHelper helper;
64 helper.Fetch(); 64 helper.Fetch();
65 helper.ExpectTotalCount("bar", 0); 65 helper.ExpectTotalCount("bar", 0);
66 } 66 }
67 67
68 } // namespace chromeos 68 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/external_metrics.cc ('k') | components/components_tests.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698