Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 1 | // 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_PROPERTY_STORE_ |
| 6 | #define SHILL_MOCK_PROPERTY_STORE_ |
| 7 | |
Hristo Stefanov | ed2c28c | 2011-11-29 15:37:30 -0800 | [diff] [blame] | 8 | #include <string> |
| 9 | |
Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 10 | #include <base/basictypes.h> |
Darin Petkov | ef34f18 | 2011-08-26 14:14:40 -0700 | [diff] [blame] | 11 | #include <gmock/gmock.h> |
| 12 | |
| 13 | #include "shill/property_store.h" |
Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 14 | |
| 15 | namespace shill { |
| 16 | |
Chris Masone | b925cc8 | 2011-06-22 15:39:57 -0700 | [diff] [blame] | 17 | class MockPropertyStore : public PropertyStore { |
Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 18 | public: |
Darin Petkov | ef34f18 | 2011-08-26 14:14:40 -0700 | [diff] [blame] | 19 | MockPropertyStore(); |
| 20 | virtual ~MockPropertyStore(); |
| 21 | |
mukesh agrawal | de29fa8 | 2011-09-16 16:16:36 -0700 | [diff] [blame] | 22 | MOCK_CONST_METHOD1(Contains, bool(const std::string&)); |
Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 23 | MOCK_METHOD3(SetBoolProperty, bool(const std::string&, bool, Error*)); |
| 24 | MOCK_METHOD3(SetInt16Property, bool(const std::string&, int16, Error*)); |
| 25 | MOCK_METHOD3(SetInt32Property, bool(const std::string&, int32, Error*)); |
| 26 | MOCK_METHOD3(SetStringProperty, bool(const std::string&, |
| 27 | const std::string&, |
| 28 | Error*)); |
Chris Masone | a8a2c25 | 2011-06-27 22:16:30 -0700 | [diff] [blame] | 29 | MOCK_METHOD3(SetStringmapProperty, bool(const std::string&, |
| 30 | const Stringmap&, |
| 31 | Error*)); |
Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 32 | MOCK_METHOD3(SetStringsProperty, bool(const std::string&, |
Chris Masone | a8a2c25 | 2011-06-27 22:16:30 -0700 | [diff] [blame] | 33 | const Strings&, |
Chris Masone | 3bd3c8c | 2011-06-13 08:20:26 -0700 | [diff] [blame] | 34 | Error*)); |
| 35 | MOCK_METHOD3(SetUint8Property, bool(const std::string&, uint8, Error*)); |
| 36 | MOCK_METHOD3(SetUint16Property, bool(const std::string&, uint16, Error*)); |
| 37 | MOCK_METHOD3(SetUint32Property, bool(const std::string&, uint32, Error*)); |
| 38 | |
| 39 | private: |
| 40 | DISALLOW_COPY_AND_ASSIGN(MockPropertyStore); |
| 41 | }; |
| 42 | |
| 43 | } // namespace shill |
| 44 | |
| 45 | #endif // SHILL_MOCK_PROPERTY_STORE_ |