Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 1 | // Copyright (c) 2013 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_SCAN_SESSION_H_ |
| 6 | #define SHILL_MOCK_SCAN_SESSION_H_ |
| 7 | |
| 8 | #include "shill/scan_session.h" |
| 9 | |
| 10 | #include <set> |
| 11 | |
| 12 | #include <gmock/gmock.h> |
| 13 | |
| 14 | #include "shill/wifi_provider.h" |
| 15 | |
| 16 | namespace shill { |
| 17 | |
| 18 | class ByteString; |
| 19 | class EventDispatcher; |
Wade Guthrie | f22681f | 2013-05-31 11:46:31 -0700 | [diff] [blame] | 20 | class Metrics; |
Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 21 | class NetlinkManager; |
| 22 | |
| 23 | class MockScanSession : public ScanSession { |
| 24 | public: |
| 25 | MockScanSession(NetlinkManager *netlink_manager, |
| 26 | EventDispatcher *dispatcher, |
| 27 | const WiFiProvider::FrequencyCountList &previous_frequencies, |
| 28 | const std::set<uint16_t> &available_frequencies, |
| 29 | uint32_t ifindex, |
| 30 | const FractionList &fractions, |
| 31 | int min_frequencies, |
| 32 | int max_frequencies, |
Wade Guthrie | f22681f | 2013-05-31 11:46:31 -0700 | [diff] [blame] | 33 | OnScanFailed on_scan_failed, |
| 34 | Metrics *metrics); |
Ben Chan | 5ea763b | 2014-08-13 11:07:54 -0700 | [diff] [blame] | 35 | ~MockScanSession() override; |
Wade Guthrie | 5a4e2ef | 2013-04-30 12:51:39 -0700 | [diff] [blame] | 36 | |
| 37 | MOCK_CONST_METHOD0(HasMoreFrequencies, bool()); |
| 38 | MOCK_METHOD1(AddSsid, void(const ByteString &ssid)); |
| 39 | MOCK_METHOD0(InitiateScan, void()); |
| 40 | |
| 41 | private: |
| 42 | DISALLOW_COPY_AND_ASSIGN(MockScanSession); |
| 43 | }; |
| 44 | |
| 45 | } // namespace shill |
| 46 | |
| 47 | #endif // SHILL_MOCK_SCAN_SESSION_H_ |