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