diff options
author | Jacob Keeler <jacob.keeler@livioradio.com> | 2018-07-16 14:36:35 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-16 14:36:35 -0700 |
commit | 4dde9552b3d9ab5fa29502810be48bdf0f793cd7 (patch) | |
tree | 4870b3b1721cd9595a7118f789c610fa1b44f83e /src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc | |
parent | 5cff788119f1e62344b94aebb7ca23cf63dc39f8 (diff) | |
parent | 2f05a630fe5f35bc46f3003d9fc35d3451c130c4 (diff) | |
download | sdl_core-4dde9552b3d9ab5fa29502810be48bdf0f793cd7.tar.gz |
Merge pull request #2199 from smartdevicelink/feature/handling_VR_help_requests
Feature/handling vr help requests
Diffstat (limited to 'src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc')
-rw-r--r-- | src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc b/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc index 7a187c46d1..5dad433d6d 100644 --- a/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc +++ b/src/components/application_manager/rpc_plugins/sdl_rpc_plugin/test/commands/mobile/delete_sub_menu_test.cc @@ -43,6 +43,7 @@ #include "application_manager/mock_message_helper.h" #include "application_manager/event_engine/event.h" #include "application_manager/mock_hmi_interface.h" +#include "application_manager/mock_help_prompt_manager.h" namespace test { namespace components { @@ -55,6 +56,7 @@ using ::testing::Return; using ::testing::ReturnRef; using ::testing::InSequence; namespace am = ::application_manager; +namespace am_test = application_manager_test; using am::commands::MessageSharedPtr; using am::event_engine::Event; using am::MockHmiInterfaces; @@ -99,6 +101,8 @@ class DeleteSubMenuRequestTest , accessor_(commands_map_, commands_lock_) , message_(CreateMessage()) , command_(CreateCommand<DeleteSubMenuRequest>(message_)) + , mock_help_prompt_manager_( + std::make_shared<am_test::MockHelpPromptManager>()) , app_(CreateMockApp()) {} am::CommandsMap commands_map_; @@ -107,6 +111,7 @@ class DeleteSubMenuRequestTest MessageSharedPtr message_; DeleteSubMenuRequestPtr command_; + std::shared_ptr<am_test::MockHelpPromptManager> mock_help_prompt_manager_; MockAppPtr app_; }; @@ -276,6 +281,9 @@ TEST_F(DeleteSubMenuRequestTest, OnEvent_DeleteSubmenu_SUCCESS) { EXPECT_CALL(*app_, commands_map()).WillOnce(Return(accessor_)); EXPECT_CALL(*app_, app_id()).WillOnce(Return(kConnectionKey)); EXPECT_CALL(*app_, RemoveCommand(_)).WillOnce(DeleteCommand(&commands_map_)); + EXPECT_CALL(*app_, help_prompt_manager()) + .WillOnce(ReturnRef(*mock_help_prompt_manager_)); + EXPECT_CALL(*mock_help_prompt_manager_, OnVrCommandDeleted(kCmdId, false)); EXPECT_CALL( mock_rpc_service_, ManageHMICommand(HMIResultCodeIs(hmi_apis::FunctionID::UI_DeleteCommand))) @@ -287,6 +295,7 @@ TEST_F(DeleteSubMenuRequestTest, OnEvent_DeleteSubmenu_SUCCESS) { ManageMobileCommand(MobileResultCodeIs(mobile_apis::Result::SUCCESS), am::commands::Command::SOURCE_SDL)); EXPECT_CALL(*app_, UpdateHash()); + DeleteSubMenuRequestPtr command = CreateCommand<DeleteSubMenuRequest>(message_); |