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

Side by Side Diff: ash/metrics/user_metrics_recorder_unittest.cc

Issue 2736573002: chromeos: Move files in //ash/common to //ash, part 2 (Closed)
Patch Set: 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
« no previous file with comments | « ash/metrics/user_metrics_recorder.cc ('k') | ash/mojo_interface_factory.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 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 "ash/metrics/user_metrics_recorder.h" 5 #include "ash/metrics/user_metrics_recorder.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "ash/common/login_status.h" 9 #include "ash/login_status.h"
10 #include "ash/common/shelf/shelf_model.h" 10 #include "ash/shelf/shelf_model.h"
11 #include "ash/common/test/test_shelf_delegate.h"
12 #include "ash/common/test/test_system_tray_delegate.h"
13 #include "ash/common/wm_shell.h"
14 #include "ash/common/wm_window.h"
15 #include "ash/test/ash_test_base.h" 11 #include "ash/test/ash_test_base.h"
12 #include "ash/test/test_shelf_delegate.h"
13 #include "ash/test/test_system_tray_delegate.h"
16 #include "ash/test/user_metrics_recorder_test_api.h" 14 #include "ash/test/user_metrics_recorder_test_api.h"
15 #include "ash/wm_shell.h"
16 #include "ash/wm_window.h"
17 #include "base/test/histogram_tester.h" 17 #include "base/test/histogram_tester.h"
18 #include "ui/aura/window.h" 18 #include "ui/aura/window.h"
19 19
20 namespace ash { 20 namespace ash {
21 namespace { 21 namespace {
22 22
23 const char kAsh_NumberOfVisibleWindowsInPrimaryDisplay[] = 23 const char kAsh_NumberOfVisibleWindowsInPrimaryDisplay[] =
24 "Ash.NumberOfVisibleWindowsInPrimaryDisplay"; 24 "Ash.NumberOfVisibleWindowsInPrimaryDisplay";
25 25
26 const char kAsh_ActiveWindowShowTypeOverTime[] = 26 const char kAsh_ActiveWindowShowTypeOverTime[] =
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 aura::Window* unpinned_window_5 = CreateTestWindow(); 220 aura::Window* unpinned_window_5 = CreateTestWindow();
221 test_shelf_delegate->AddShelfItem(WmWindow::Get(unpinned_window_5)); 221 test_shelf_delegate->AddShelfItem(WmWindow::Get(unpinned_window_5));
222 222
223 user_metrics_recorder_test_api()->RecordPeriodicMetrics(); 223 user_metrics_recorder_test_api()->RecordPeriodicMetrics();
224 histograms().ExpectBucketCount(kAsh_Shelf_NumberOfItems, 5, 1); 224 histograms().ExpectBucketCount(kAsh_Shelf_NumberOfItems, 5, 1);
225 histograms().ExpectBucketCount(kAsh_Shelf_NumberOfPinnedItems, 2, 1); 225 histograms().ExpectBucketCount(kAsh_Shelf_NumberOfPinnedItems, 2, 1);
226 histograms().ExpectBucketCount(kAsh_Shelf_NumberOfUnpinnedItems, 3, 1); 226 histograms().ExpectBucketCount(kAsh_Shelf_NumberOfUnpinnedItems, 3, 1);
227 } 227 }
228 228
229 } // namespace ash 229 } // namespace ash
OLDNEW
« no previous file with comments | « ash/metrics/user_metrics_recorder.cc ('k') | ash/mojo_interface_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698