blob: 00629fa17c45ac5642e7be8247064a3c7519fa37 [file] [log] [blame]
Chris Masone3bd3c8c2011-06-13 08:20:26 -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
Ben Chanc45688b2014-07-02 23:50:45 -07005#ifndef SHILL_MOCK_PROPERTY_STORE_H_
6#define SHILL_MOCK_PROPERTY_STORE_H_
Chris Masone3bd3c8c2011-06-13 08:20:26 -07007
Hristo Stefanoved2c28c2011-11-29 15:37:30 -08008#include <string>
9
Ben Chancc67c522014-09-03 07:19:18 -070010#include <base/macros.h>
Darin Petkovef34f182011-08-26 14:14:40 -070011#include <gmock/gmock.h>
12
13#include "shill/property_store.h"
Chris Masone3bd3c8c2011-06-13 08:20:26 -070014
15namespace shill {
16
Chris Masoneb925cc82011-06-22 15:39:57 -070017class MockPropertyStore : public PropertyStore {
Chris Masone3bd3c8c2011-06-13 08:20:26 -070018 public:
Darin Petkovef34f182011-08-26 14:14:40 -070019 MockPropertyStore();
Ben Chan5ea763b2014-08-13 11:07:54 -070020 ~MockPropertyStore() override;
Darin Petkovef34f182011-08-26 14:14:40 -070021
mukesh agrawalde29fa82011-09-16 16:16:36 -070022 MOCK_CONST_METHOD1(Contains, bool(const std::string&));
Chris Masone3bd3c8c2011-06-13 08:20:26 -070023 MOCK_METHOD3(SetBoolProperty, bool(const std::string&, bool, Error*));
Ben Chan7fab8972014-08-10 17:14:46 -070024 MOCK_METHOD3(SetInt16Property, bool(const std::string&, int16_t, Error*));
25 MOCK_METHOD3(SetInt32Property, bool(const std::string&, int32_t, Error*));
Chris Masone3bd3c8c2011-06-13 08:20:26 -070026 MOCK_METHOD3(SetStringProperty, bool(const std::string&,
27 const std::string&,
28 Error*));
Chris Masonea8a2c252011-06-27 22:16:30 -070029 MOCK_METHOD3(SetStringmapProperty, bool(const std::string&,
30 const Stringmap&,
31 Error*));
Chris Masone3bd3c8c2011-06-13 08:20:26 -070032 MOCK_METHOD3(SetStringsProperty, bool(const std::string&,
Chris Masonea8a2c252011-06-27 22:16:30 -070033 const Strings&,
Chris Masone3bd3c8c2011-06-13 08:20:26 -070034 Error*));
Ben Chan7fab8972014-08-10 17:14:46 -070035 MOCK_METHOD3(SetUint8Property, bool(const std::string&, uint8_t, Error*));
36 MOCK_METHOD3(SetUint16Property, bool(const std::string&, uint16_t, Error*));
mukesh agrawale7c7e652013-06-18 17:19:39 -070037 MOCK_METHOD3(SetUint16sProperty, bool(const std::string&,
Paul Stewart1e006c62015-06-16 12:29:06 -070038 const Uint16s&, Error*));
Ben Chan7fab8972014-08-10 17:14:46 -070039 MOCK_METHOD3(SetUint32Property, bool(const std::string&, uint32_t, Error*));
40 MOCK_METHOD3(SetUint64Property, bool(const std::string&, uint64_t, Error*));
mukesh agrawal8abd2f62012-01-30 14:56:14 -080041 MOCK_METHOD2(ClearProperty, bool(const std::string&, Error*));
Chris Masone3bd3c8c2011-06-13 08:20:26 -070042
43 private:
44 DISALLOW_COPY_AND_ASSIGN(MockPropertyStore);
45};
46
47} // namespace shill
48
Ben Chanc45688b2014-07-02 23:50:45 -070049#endif // SHILL_MOCK_PROPERTY_STORE_H_