blob: fa58232fed06bdb3d2d2483a2ce33cb36fc9b8b9 [file] [log] [blame]
mukesh agrawal9da07772013-05-15 14:15:17 -07001// 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 Vakulenko8a532292014-06-16 17:18:44 -07008#include <string>
9
mukesh agrawal9da07772013-05-15 14:15:17 -070010#include <gmock/gmock.h>
11
12#include "shill/virtual_device.h"
13
14namespace shill {
15
16class 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);
Ben Chan5ea763b2014-08-13 11:07:54 -070025 ~MockVirtualDevice() override;
mukesh agrawal9da07772013-05-15 14:15:17 -070026
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_