Thieu Le | 3426c8f | 2012-01-11 17:35:11 -0800 | [diff] [blame] | 1 | // Copyright (c) 2012 The Chromium OS Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | #ifndef SHILL_MOCK_METRICS_ |
| 6 | #define SHILL_MOCK_METRICS_ |
| 7 | |
| 8 | #include "shill/metrics.h" |
| 9 | |
Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 10 | #include <gmock/gmock.h> |
| 11 | |
Thieu Le | 3426c8f | 2012-01-11 17:35:11 -0800 | [diff] [blame] | 12 | namespace shill { |
| 13 | |
| 14 | class MockMetrics : public Metrics { |
| 15 | public: |
Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 16 | explicit MockMetrics(EventDispatcher *dispatcher); |
Thieu Le | 3426c8f | 2012-01-11 17:35:11 -0800 | [diff] [blame] | 17 | virtual ~MockMetrics(); |
| 18 | |
Thieu Le | 6c1e3bb | 2013-02-06 15:20:35 -0800 | [diff] [blame] | 19 | MOCK_METHOD0(Start, void()); |
| 20 | MOCK_METHOD0(Stop, void()); |
Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 21 | MOCK_METHOD1(NotifyDeviceScanFinished, void(int interface_index)); |
Thieu Le | a20cbc2 | 2012-01-09 22:01:43 +0000 | [diff] [blame] | 22 | MOCK_METHOD1(NotifyDefaultServiceChanged, void(const Service *service)); |
Darin Petkov | 58f0b6d | 2012-06-12 12:52:30 +0200 | [diff] [blame] | 23 | MOCK_METHOD2(NotifyServiceStateChanged, |
| 24 | void(const Service *service, Service::ConnectState new_state)); |
Thieu Le | 5133b71 | 2013-02-19 14:47:21 -0800 | [diff] [blame] | 25 | MOCK_METHOD0(NotifyCorruptedProfile, void()); |
Thieu Le | 85e050b | 2012-03-13 15:04:38 -0700 | [diff] [blame] | 26 | MOCK_METHOD3(SendEnumToUMA, bool(const std::string &name, int sample, |
| 27 | int max)); |
| 28 | MOCK_METHOD5(SendToUMA, bool(const std::string &name, int sample, int min, |
| 29 | int max, int num_buckets)); |
Thieu Le | a20cbc2 | 2012-01-09 22:01:43 +0000 | [diff] [blame] | 30 | |
Thieu Le | 3426c8f | 2012-01-11 17:35:11 -0800 | [diff] [blame] | 31 | private: |
| 32 | DISALLOW_COPY_AND_ASSIGN(MockMetrics); |
| 33 | }; |
| 34 | |
Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 35 | } // namespace shill |
Thieu Le | 3426c8f | 2012-01-11 17:35:11 -0800 | [diff] [blame] | 36 | |
| 37 | #endif // SHILL_MOCK_METRICS_ |