blob: 462bc21e00d04ff20581af028972f736b75ab271 [file] [log] [blame]
Chris Masone9be4a9d2011-05-16 15:44:09 -07001// Copyright (c) 2011 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_DEVICE_
6#define SHILL_MOCK_DEVICE_
7
Chris Masone46eaaf52011-05-24 13:08:30 -07008#include <string>
9
Chris Masone9be4a9d2011-05-16 15:44:09 -070010#include <base/memory/ref_counted.h>
11#include <gmock/gmock.h>
12
13#include "shill/device.h"
14
15namespace shill {
16
Chris Masone9be4a9d2011-05-16 15:44:09 -070017class MockDevice : public Device {
18 public:
Chris Masone9be4a9d2011-05-16 15:44:09 -070019 MockDevice(ControlInterface *control_interface,
Paul Stewartb50f0b92011-05-16 16:31:42 -070020 EventDispatcher *dispatcher,
Chris Masonea82b7112011-05-25 15:16:29 -070021 Manager *manager,
22 const std::string &link_name,
Chris Masone626719f2011-08-18 16:58:48 -070023 const std::string &address,
Chris Masonea82b7112011-05-25 15:16:29 -070024 int interface_index);
25 virtual ~MockDevice();
Chris Masone9be4a9d2011-05-16 15:44:09 -070026
Darin Petkov6f9eaa32011-08-09 15:26:44 -070027 MOCK_METHOD0(Start, void());
28 MOCK_METHOD0(Stop, void());
Darin Petkovc0865312011-09-16 15:31:20 -070029 MOCK_METHOD1(Scan, void(Error *error));
Paul Stewartfdd16072011-09-16 12:41:35 -070030 MOCK_CONST_METHOD1(TechnologyIs,
31 bool(const Technology::Identifier technology));
Paul Stewarta41e38d2011-11-11 07:47:29 -080032 MOCK_METHOD1(Load, bool(StoreInterface*));
Chris Masone877ff982011-09-21 16:18:24 -070033 MOCK_METHOD1(Save, bool(StoreInterface*));
Paul Stewart2bf1d352011-12-06 15:02:55 -080034 MOCK_METHOD0(DisableIPv6, void());
35 MOCK_METHOD0(EnableIPv6, void());
36 MOCK_METHOD0(EnableIPv6Privacy, void());
Gaurav Shah435de2c2011-11-17 19:01:07 -080037 MOCK_CONST_METHOD0(technology, Technology::Identifier());
Chris Masone9be4a9d2011-05-16 15:44:09 -070038
39 private:
40 DISALLOW_COPY_AND_ASSIGN(MockDevice);
41};
42
43} // namespace shill
44
45#endif // SHILL_MOCK_DEVICE_