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

Side by Side Diff: src/platform/metrics/metrics_daemon.h

Issue 1990001: Add tests for the D-Bus MessageFilter. (Closed)
Patch Set: Assume current folder is writable. This way tests can run in parallel. Created 10 years, 7 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 | « no previous file | src/platform/metrics/metrics_daemon_test.cc » ('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) 2010 The Chromium OS Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium OS 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 #ifndef METRICS_DAEMON_H_ 5 #ifndef METRICS_DAEMON_H_
6 #define METRICS_DAEMON_H_ 6 #define METRICS_DAEMON_H_
7 7
8 #include <dbus/dbus.h> 8 #include <dbus/dbus.h>
9 #include <glib.h> 9 #include <glib.h>
10 #include <time.h> 10 #include <time.h>
(...skipping 21 matching lines...) Expand all
32 // forking. 32 // forking.
33 void Run(bool run_as_daemon); 33 void Run(bool run_as_daemon);
34 34
35 private: 35 private:
36 friend class MetricsDaemonTest; 36 friend class MetricsDaemonTest;
37 FRIEND_TEST(MetricsDaemonTest, LogDailyUseRecord); 37 FRIEND_TEST(MetricsDaemonTest, LogDailyUseRecord);
38 FRIEND_TEST(MetricsDaemonTest, LookupNetworkState); 38 FRIEND_TEST(MetricsDaemonTest, LookupNetworkState);
39 FRIEND_TEST(MetricsDaemonTest, LookupPowerState); 39 FRIEND_TEST(MetricsDaemonTest, LookupPowerState);
40 FRIEND_TEST(MetricsDaemonTest, LookupScreenSaverState); 40 FRIEND_TEST(MetricsDaemonTest, LookupScreenSaverState);
41 FRIEND_TEST(MetricsDaemonTest, LookupSessionState); 41 FRIEND_TEST(MetricsDaemonTest, LookupSessionState);
42 FRIEND_TEST(MetricsDaemonTest, MessageFilter);
42 FRIEND_TEST(MetricsDaemonTest, NetStateChanged); 43 FRIEND_TEST(MetricsDaemonTest, NetStateChanged);
43 FRIEND_TEST(MetricsDaemonTest, PowerStateChanged); 44 FRIEND_TEST(MetricsDaemonTest, PowerStateChanged);
44 FRIEND_TEST(MetricsDaemonTest, PublishMetric); 45 FRIEND_TEST(MetricsDaemonTest, PublishMetric);
45 FRIEND_TEST(MetricsDaemonTest, ScreenSaverStateChanged); 46 FRIEND_TEST(MetricsDaemonTest, ScreenSaverStateChanged);
46 FRIEND_TEST(MetricsDaemonTest, SessionStateChanged); 47 FRIEND_TEST(MetricsDaemonTest, SessionStateChanged);
47 FRIEND_TEST(MetricsDaemonTest, SetUserActiveState); 48 FRIEND_TEST(MetricsDaemonTest, SetUserActiveState);
48 49
49 // The network states (see network_states.h). 50 // The network states (see network_states.h).
50 enum NetworkState { 51 enum NetworkState {
51 kUnknownNetworkState = -1, // Initial/unknown network state. 52 kUnknownNetworkState = -1, // Initial/unknown network state.
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 219
219 // Sleep period until the next daily usage aggregation performed by 220 // Sleep period until the next daily usage aggregation performed by
220 // the daily use monitor (see ScheduleUseMonitor). 221 // the daily use monitor (see ScheduleUseMonitor).
221 int usemon_interval_; 222 int usemon_interval_;
222 223
223 // Scheduled daily use monitor source (see ScheduleUseMonitor). 224 // Scheduled daily use monitor source (see ScheduleUseMonitor).
224 GSource* usemon_source_; 225 GSource* usemon_source_;
225 }; 226 };
226 227
227 #endif // METRICS_DAEMON_H_ 228 #endif // METRICS_DAEMON_H_
OLDNEW
« no previous file with comments | « no previous file | src/platform/metrics/metrics_daemon_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698