mukesh agrawal | 9da0777 | 2013-05-15 14:15:17 -0700 | [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_VIRTUAL_DEVICE_H_ |
| 6 | #define SHILL_MOCK_VIRTUAL_DEVICE_H_ |
| 7 | |
Alex Vakulenko | 8a53229 | 2014-06-16 17:18:44 -0700 | [diff] [blame] | 8 | #include <string> |
| 9 | |
mukesh agrawal | 9da0777 | 2013-05-15 14:15:17 -0700 | [diff] [blame] | 10 | #include <gmock/gmock.h> |
| 11 | |
| 12 | #include "shill/virtual_device.h" |
| 13 | |
| 14 | namespace shill { |
| 15 | |
| 16 | class MockVirtualDevice : public VirtualDevice { |
| 17 | public: |
| 18 | MockVirtualDevice(ControlInterface *control, |
| 19 | EventDispatcher *dispatcher, |
| 20 | Metrics *metrics, |
| 21 | Manager *manager, |
| 22 | const std::string &link_name, |
| 23 | int interface_index, |
| 24 | Technology::Identifier technology); |
| 25 | virtual ~MockVirtualDevice(); |
| 26 | |
| 27 | MOCK_METHOD2(Stop, |
| 28 | void(Error *error, const EnabledStateChangedCallback &callback)); |
| 29 | MOCK_METHOD1(UpdateIPConfig, |
| 30 | void(const IPConfig::Properties &properties)); |
| 31 | MOCK_METHOD0(DropConnection, void()); |
| 32 | MOCK_METHOD1(SetEnabled, void(bool)); |
| 33 | |
| 34 | private: |
| 35 | DISALLOW_COPY_AND_ASSIGN(MockVirtualDevice); |
| 36 | }; |
| 37 | |
| 38 | } // namespace shill |
| 39 | |
| 40 | #endif // SHILL_MOCK_VIRTUAL_DEVICE_H_ |