diff options
Diffstat (limited to 'src/components/remote_control/test/include/mock_resource_allocation_manager.h')
-rw-r--r-- | src/components/remote_control/test/include/mock_resource_allocation_manager.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/components/remote_control/test/include/mock_resource_allocation_manager.h b/src/components/remote_control/test/include/mock_resource_allocation_manager.h new file mode 100644 index 0000000000..6337d8a32a --- /dev/null +++ b/src/components/remote_control/test/include/mock_resource_allocation_manager.h @@ -0,0 +1,40 @@ +#ifndef SRC_COMPONENTS_REMOTE_CONTROL_TEST_INCLUDE_MOCK_RESOURCE_ALLOCATION_MANAGER_H_ +#define SRC_COMPONENTS_REMOTE_CONTROL_TEST_INCLUDE_MOCK_RESOURCE_ALLOCATION_MANAGER_H_ + +#include "gmock/gmock.h" +#include "remote_control/resource_allocation_manager.h" + +namespace test { +namespace components { +namespace remote_control_test { + +class MockResourceAllocationManager + : public remote_control::ResourceAllocationManager { + public: + MOCK_METHOD2(AcquireResource, + remote_control::AcquireResult::eType( + const std::string& module_type, const uint32_t app_id)); + MOCK_METHOD2(ForceAcquireResource, + void(const std::string& module_type, const uint32_t app_id)); + MOCK_METHOD2(OnDriverDisallowed, + void(const std::string& module_type, const uint32_t app_id)); + MOCK_METHOD2(OnApplicationEvent, + void(functional_modules::ApplicationEvent event, + application_manager::ApplicationSharedPtr application)); + MOCK_METHOD1(OnPolicyEvent, void(functional_modules::PolicyEvent event)); + MOCK_METHOD1(SetAccessMode, + void(const hmi_apis::Common_RCAccessMode::eType access_mode)); + MOCK_CONST_METHOD0(GetAccessMode, hmi_apis::Common_RCAccessMode::eType()); + MOCK_METHOD3(SetResourceState, + void(const std::string& module_type, + const uint32_t app_id, + const remote_control::ResourceState::eType state)); + MOCK_CONST_METHOD1(IsResourceFree, bool(const std::string& module_type)); + MOCK_METHOD0(ResetAllAllocations, void()); +}; + +} // namespace remote_control_test +} // namespace components +} // namespace test + +#endif // SRC_COMPONENTS_REMOTE_CONTROL_TEST_INCLUDE_MOCK_RESOURCE_ALLOCATION_MANAGER_H_ |