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

Side by Side Diff: chrome/browser/metrics/metrics_service_browsertest.cc

Issue 624173002: replace OVERRIDE and FINAL with override and final in chrome/browser/[j-q]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 6 years, 2 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 (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 // Tests the MetricsService stat recording to make sure that the numbers are 5 // Tests the MetricsService stat recording to make sure that the numbers are
6 // what we expect. 6 // what we expect.
7 7
8 #include "components/metrics/metrics_service.h" 8 #include "components/metrics/metrics_service.h"
9 9
10 #include <string> 10 #include <string>
(...skipping 11 matching lines...) Expand all
22 #include "chrome/common/url_constants.h" 22 #include "chrome/common/url_constants.h"
23 #include "chrome/test/base/in_process_browser_test.h" 23 #include "chrome/test/base/in_process_browser_test.h"
24 #include "chrome/test/base/ui_test_utils.h" 24 #include "chrome/test/base/ui_test_utils.h"
25 #include "content/public/test/browser_test_utils.h" 25 #include "content/public/test/browser_test_utils.h"
26 #include "net/base/filename_util.h" 26 #include "net/base/filename_util.h"
27 #include "ui/base/window_open_disposition.h" 27 #include "ui/base/window_open_disposition.h"
28 #include "url/gurl.h" 28 #include "url/gurl.h"
29 29
30 class MetricsServiceBrowserTest : public InProcessBrowserTest { 30 class MetricsServiceBrowserTest : public InProcessBrowserTest {
31 public: 31 public:
32 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { 32 virtual void SetUpCommandLine(CommandLine* command_line) override {
33 // Enable the metrics service for testing (in recording-only mode). 33 // Enable the metrics service for testing (in recording-only mode).
34 command_line->AppendSwitch(switches::kMetricsRecordingOnly); 34 command_line->AppendSwitch(switches::kMetricsRecordingOnly);
35 } 35 }
36 36
37 // Open a couple of tabs of random content. 37 // Open a couple of tabs of random content.
38 void OpenTabs() { 38 void OpenTabs() {
39 const int kBrowserTestFlags = 39 const int kBrowserTestFlags =
40 ui_test_utils::BROWSER_TEST_WAIT_FOR_TAB | 40 ui_test_utils::BROWSER_TEST_WAIT_FOR_TAB |
41 ui_test_utils::BROWSER_TEST_WAIT_FOR_NAVIGATION; 41 ui_test_utils::BROWSER_TEST_WAIT_FOR_NAVIGATION;
42 42
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 // Verify that the expected stability metrics were recorded. 103 // Verify that the expected stability metrics were recorded.
104 EXPECT_EQ(1, prefs->GetInteger(metrics::prefs::kStabilityLaunchCount)); 104 EXPECT_EQ(1, prefs->GetInteger(metrics::prefs::kStabilityLaunchCount));
105 EXPECT_EQ(4, prefs->GetInteger(prefs::kStabilityPageLoadCount)); 105 EXPECT_EQ(4, prefs->GetInteger(prefs::kStabilityPageLoadCount));
106 EXPECT_EQ(1, prefs->GetInteger(prefs::kStabilityRendererCrashCount)); 106 EXPECT_EQ(1, prefs->GetInteger(prefs::kStabilityRendererCrashCount));
107 // TODO(isherman): We should also verify that 107 // TODO(isherman): We should also verify that
108 // metrics::prefs::kStabilityExitedCleanly 108 // metrics::prefs::kStabilityExitedCleanly
109 // is set to true, but this preference isn't set until the browser 109 // is set to true, but this preference isn't set until the browser
110 // exits... it's not clear to me how to test that. 110 // exits... it's not clear to me how to test that.
111 } 111 }
112 112
OLDNEW
« no previous file with comments | « chrome/browser/metrics/google_update_metrics_provider_win.h ('k') | chrome/browser/metrics/omnibox_metrics_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698