Unit Test: Adding unit test cases UsrMgr
This changes set will add needed unit test cases for User Manager
Change-Id: I848cdbde528d41c2a09abcf35527044b6084f023
Signed-off-by: Abhilash Raju <abhilash.kollam@gmail.com>
diff --git a/test/mock_user_mgr.hpp b/test/mock_user_mgr.hpp
index 99f2b37..b301ba7 100644
--- a/test/mock_user_mgr.hpp
+++ b/test/mock_user_mgr.hpp
@@ -25,6 +25,15 @@
friend class TestUserMgr;
};
-
+class MockUser : public Users
+{
+ public:
+ MockUser(sdbusplus::bus::bus& bus, const char* objPath,
+ std::vector<std::string> groupNames, const std::string& priv,
+ bool enabled, UserMgr& parent) :
+ Users(bus, objPath, groupNames, priv, enabled, parent)
+ {}
+ MOCK_METHOD0(createSecretKey, std::string());
+};
} // namespace user
} // namespace phosphor