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

Side by Side Diff: ios/chrome/browser/metrics/mobile_session_shutdown_metrics_provider_unittest.mm

Issue 2771233002: Remove the wrapper functions content::RecordAction et al (Closed)
Patch Set: Rebased Created 3 years, 9 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "ios/chrome/browser/metrics/mobile_session_shutdown_metrics_provider.h" 5 #include "ios/chrome/browser/metrics/mobile_session_shutdown_metrics_provider.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "base/metrics/user_metrics.h"
12 #include "base/test/histogram_tester.h" 11 #include "base/test/histogram_tester.h"
13 #include "base/test/test_simple_task_runner.h" 12 #include "base/test/test_simple_task_runner.h"
14 #include "components/metrics/metrics_pref_names.h" 13 #include "components/metrics/metrics_pref_names.h"
15 #include "components/metrics/metrics_service.h" 14 #include "components/metrics/metrics_service.h"
16 #include "components/metrics/metrics_state_manager.h" 15 #include "components/metrics/metrics_state_manager.h"
17 #include "components/metrics/test_enabled_state_provider.h" 16 #include "components/metrics/test_enabled_state_provider.h"
18 #include "components/metrics/test_metrics_service_client.h" 17 #include "components/metrics/test_metrics_service_client.h"
19 #include "components/prefs/testing_pref_service.h" 18 #include "components/prefs/testing_pref_service.h"
20 #include "testing/gtest/include/gtest/gtest-param-test.h" 19 #include "testing/gtest/include/gtest/gtest-param-test.h"
21 #include "testing/gtest/include/gtest/gtest.h" 20 #include "testing/gtest/include/gtest/gtest.h"
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 // Now call the method under test and verify exactly one sample is written to 172 // Now call the method under test and verify exactly one sample is written to
174 // the expected bucket. 173 // the expected bucket.
175 metrics_provider_->ProvideInitialStabilityMetrics(nullptr); 174 metrics_provider_->ProvideInitialStabilityMetrics(nullptr);
176 histogram_tester.ExpectUniqueSample("Stability.MobileSessionShutdownType", 175 histogram_tester.ExpectUniqueSample("Stability.MobileSessionShutdownType",
177 expected_buckets[GetParam()], 1); 176 expected_buckets[GetParam()], 1);
178 } 177 }
179 178
180 INSTANTIATE_TEST_CASE_P(/* No InstantiationName */, 179 INSTANTIATE_TEST_CASE_P(/* No InstantiationName */,
181 MobileSessionShutdownMetricsProviderTest, 180 MobileSessionShutdownMetricsProviderTest,
182 testing::Range(0, 32)); 181 testing::Range(0, 32));
OLDNEW
« no previous file with comments | « ios/chrome/browser/metrics/ios_chrome_stability_metrics_provider.h ('k') | ios/chrome/browser/tabs/tab_model.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698