1f77189f7SLei YU #include "utils.hpp"
2f77189f7SLei YU 
3f77189f7SLei YU #include <gmock/gmock.h>
4f77189f7SLei YU 
5f77189f7SLei YU namespace utils
6f77189f7SLei YU {
7f77189f7SLei YU 
8f77189f7SLei YU class MockedUtils : public UtilsInterface
9f77189f7SLei YU {
10f77189f7SLei YU   public:
11f77189f7SLei YU     virtual ~MockedUtils() = default;
12f77189f7SLei YU 
13f77189f7SLei YU     MOCK_CONST_METHOD1(getPSUInventoryPath,
14f77189f7SLei YU                        std::vector<std::string>(sdbusplus::bus::bus& bus));
15f77189f7SLei YU 
16f77189f7SLei YU     MOCK_CONST_METHOD3(getService,
17f77189f7SLei YU                        std::string(sdbusplus::bus::bus& bus, const char* path,
18f77189f7SLei YU                                    const char* interface));
19f77189f7SLei YU 
20d0bbfa9eSLei YU     MOCK_CONST_METHOD3(getServices,
21d0bbfa9eSLei YU                        std::vector<std::string>(sdbusplus::bus::bus& bus,
22d0bbfa9eSLei YU                                                 const char* path,
23d0bbfa9eSLei YU                                                 const char* interface));
24d0bbfa9eSLei YU 
25f77189f7SLei YU     MOCK_CONST_METHOD1(getVersionId, std::string(const std::string& version));
26f77189f7SLei YU 
275f3584d4SLei YU     MOCK_CONST_METHOD1(getVersion,
285f3584d4SLei YU                        std::string(const std::string& psuInventoryPath));
295f3584d4SLei YU 
30f77189f7SLei YU     MOCK_CONST_METHOD5(getPropertyImpl,
31f77189f7SLei YU                        any(sdbusplus::bus::bus& bus, const char* service,
32f77189f7SLei YU                            const char* path, const char* interface,
33f77189f7SLei YU                            const char* propertyName));
34f77189f7SLei YU };
35f77189f7SLei YU 
36*ff83c2a0SLei YU inline const UtilsInterface& getUtils()
37f77189f7SLei YU {
38f77189f7SLei YU     static MockedUtils utils;
39f77189f7SLei YU     return utils;
40f77189f7SLei YU }
41f77189f7SLei YU 
42f77189f7SLei YU } // namespace utils
43