blob: ef8bc6af65c2f2166a7094093d16880028b5ddeb [file] [log] [blame]
Peter Qiu7e8b8ee2014-11-25 13:55:57 -08001// Copyright 2014 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_CLAIMER_H_
6#define SHILL_MOCK_DEVICE_CLAIMER_H_
7
8#include "shill/device_claimer.h"
9
10#include <string>
11
12#include <base/macros.h>
13#include <gmock/gmock.h>
14
15namespace shill {
16
17class MockDeviceClaimer : public DeviceClaimer {
18 public:
Paul Stewart1e006c62015-06-16 12:29:06 -070019 explicit MockDeviceClaimer(const std::string& dbus_service_name);
Peter Qiu7e8b8ee2014-11-25 13:55:57 -080020 ~MockDeviceClaimer() override;
21
Paul Stewart1e006c62015-06-16 12:29:06 -070022 MOCK_METHOD2(Claim, bool(const std::string& device_name, Error* error));
23 MOCK_METHOD2(Release, bool(const std::string& device_name, Error* error));
Peter Qiu7e8b8ee2014-11-25 13:55:57 -080024 MOCK_METHOD0(DevicesClaimed, bool());
Paul Stewart1e006c62015-06-16 12:29:06 -070025 MOCK_METHOD1(IsDeviceReleased, bool(const std::string& device_name));
Peter Qiu1d499ed2015-01-30 16:01:27 -080026 MOCK_CONST_METHOD0(default_claimer, bool());
Peter Qiu7e8b8ee2014-11-25 13:55:57 -080027
28 private:
29 DISALLOW_COPY_AND_ASSIGN(MockDeviceClaimer);
30};
31
32} // namespace shill
33
34#endif // SHILL_MOCK_DEVICE_CLAIMER_H_