diff options
Diffstat (limited to 'src/components/application_manager/rpc_plugins/vehicle_info_plugin')
12 files changed, 37 insertions, 37 deletions
diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/commands/hmi/vi_is_ready_request.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/commands/hmi/vi_is_ready_request.cc index 3401849861..04bcc435ba 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/commands/hmi/vi_is_ready_request.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/commands/hmi/vi_is_ready_request.cc @@ -100,7 +100,7 @@ void VIIsReadyRequest::onTimeOut() { } void VIIsReadyRequest::SendMessageToHMI() { - utils::SharedPtr<smart_objects::SmartObject> get_type( + std::shared_ptr<smart_objects::SmartObject> get_type( MessageHelper::CreateModuleInfoSO( hmi_apis::FunctionID::VehicleInfo_GetVehicleType, application_manager_)); diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_app_extension.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_app_extension.cc index ed4755a818..a19fdbee97 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_app_extension.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_app_extension.cc @@ -118,7 +118,7 @@ VehicleInfoAppExtension& VehicleInfoAppExtension::ExtractVIExtension( DCHECK(ext_ptr); DCHECK(dynamic_cast<VehicleInfoAppExtension*>(ext_ptr.get())); auto vi_app_extension = - application_manager::AppExtensionPtr::static_pointer_cast< + std::static_pointer_cast< VehicleInfoAppExtension>(ext_ptr); DCHECK(vi_app_extension); return *vi_app_extension; diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_plugin.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_plugin.cc index 7b94d22312..b16993b002 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_plugin.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/src/vehicle_info_plugin.cc @@ -74,7 +74,7 @@ void VehicleInfoPlugin::OnApplicationEvent( plugins::ApplicationEvent event, app_mngr::ApplicationSharedPtr application) { if (plugins::ApplicationEvent::kApplicationRegistered == event) { - application->AddExtension(new VehicleInfoAppExtension(*this, *application)); + application->AddExtension(std::make_shared<VehicleInfoAppExtension>(*this, *application)); } } diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_get_vehicle_data_response_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_get_vehicle_data_response_test.cc index ddfc8e8a55..0508f0cdd6 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_get_vehicle_data_response_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_get_vehicle_data_response_test.cc @@ -35,7 +35,7 @@ #include <vector> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "smart_objects/smart_object.h" #include "application_manager/smart_object_keys.h" #include "application_manager/commands/commands_test.h" @@ -65,7 +65,7 @@ using vehicle_info_plugin::commands::VIGetVehicleDataResponse; using am::event_engine::Event; using test::components::event_engine_test::MockEventDispatcher; -typedef SharedPtr<VIGetVehicleDataResponse> VIGetVehicleDataResponsePtr; +typedef std::shared_ptr<VIGetVehicleDataResponse> VIGetVehicleDataResponsePtr; namespace { const uint32_t kConnectionKey = 2u; diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_is_ready_request_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_is_ready_request_test.cc index d0093f45cf..d4477d5d5f 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_is_ready_request_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/hmi/vi_is_ready_request_test.cc @@ -33,7 +33,7 @@ #include "hmi/vi_is_ready_request.h" #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "smart_objects/smart_object.h" #include "application_manager/smart_object_keys.h" #include "application_manager/commands/command_request_test.h" @@ -59,7 +59,7 @@ using am::commands::MessageSharedPtr; using vehicle_info_plugin::commands::VIIsReadyRequest; using am::event_engine::Event; -typedef SharedPtr<VIIsReadyRequest> VIIsReadyRequestPtr; +typedef std::shared_ptr<VIIsReadyRequest> VIIsReadyRequestPtr; class VIIsReadyRequestTest : public CommandRequestTest<CommandsTestMocks::kIsNice> { diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/diagnostic_message_request_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/diagnostic_message_request_test.cc index 3f684cae3f..9cdf60b1ea 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/diagnostic_message_request_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/diagnostic_message_request_test.cc @@ -35,7 +35,7 @@ #include <vector> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "smart_objects/smart_object.h" #include "application_manager/smart_object_keys.h" #include "application_manager/commands/commands_test.h" @@ -63,7 +63,7 @@ using vehicle_info_plugin::commands::DiagnosticMessageRequest; using am::event_engine::Event; namespace mobile_result = mobile_apis::Result; -typedef SharedPtr<DiagnosticMessageRequest> DiagnosticMessageRequestPtr; +typedef std::shared_ptr<DiagnosticMessageRequest> DiagnosticMessageRequestPtr; namespace { const uint32_t kConnectionKey = 2u; diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_dtcs_request_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_dtcs_request_test.cc index 9719d3ceed..4473a36c63 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_dtcs_request_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_dtcs_request_test.cc @@ -35,7 +35,7 @@ #include <vector> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "smart_objects/smart_object.h" #include "application_manager/smart_object_keys.h" #include "application_manager/commands/commands_test.h" @@ -64,7 +64,7 @@ using am::MockMessageHelper; using testing::Mock; namespace mobile_result = mobile_apis::Result; -typedef SharedPtr<GetDTCsRequest> GetDTCsRequestPtr; +typedef std::shared_ptr<GetDTCsRequest> GetDTCsRequestPtr; class GetDTCsRequestTest : public CommandRequestTest<CommandsTestMocks::kIsNice> { diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_vehicle_data_request_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_vehicle_data_request_test.cc index 4ad8a84189..a88d362968 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_vehicle_data_request_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/get_vehicle_data_request_test.cc @@ -35,7 +35,7 @@ #include <vector> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "smart_objects/smart_object.h" #include "application_manager/smart_object_keys.h" #include "application_manager/commands/commands_test.h" @@ -63,7 +63,7 @@ using vehicle_info_plugin::commands::GetVehicleDataRequest; using am::event_engine::Event; namespace mobile_result = mobile_apis::Result; -typedef SharedPtr<GetVehicleDataRequest> GetVehicleDataRequestPtr; +typedef std::shared_ptr<GetVehicleDataRequest> GetVehicleDataRequestPtr; namespace { const uint32_t kConnectionKey = 2u; @@ -160,7 +160,7 @@ TEST_F(GetVehicleDataRequestTest, (*command_msg)[am::strings::params][am::strings::connection_key] = kConnectionKey; - SharedPtr<UnwrappedGetVehicleDataRequest> command( + std::shared_ptr<UnwrappedGetVehicleDataRequest> command( CreateCommand<UnwrappedGetVehicleDataRequest>(command_msg)); const am::VehicleData kEmptyVehicleData; @@ -212,7 +212,7 @@ TEST_F(GetVehicleDataRequestTest, OnEvent_UnknownEvent_UNSUCCESS) { (*command_msg)[am::strings::params][am::strings::connection_key] = kConnectionKey; - SharedPtr<UnwrappedGetVehicleDataRequest> command( + std::shared_ptr<UnwrappedGetVehicleDataRequest> command( CreateCommand<UnwrappedGetVehicleDataRequest>(command_msg)); Event event(hmi_apis::FunctionID::INVALID_ENUM); @@ -232,7 +232,7 @@ TEST_F(GetVehicleDataRequestTest, OnEvent_DataNotAvailable_SUCCESS) { (*command_msg)[am::strings::params][am::strings::connection_key] = kConnectionKey; - SharedPtr<UnwrappedGetVehicleDataRequest> command( + std::shared_ptr<UnwrappedGetVehicleDataRequest> command( CreateCommand<UnwrappedGetVehicleDataRequest>(command_msg)); MessageSharedPtr event_msg(CreateMessage(smart_objects::SmartType_Map)); diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/on_vehicle_data_notification_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/on_vehicle_data_notification_test.cc index 3cc5af575e..1e8a289637 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/on_vehicle_data_notification_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/on_vehicle_data_notification_test.cc @@ -36,7 +36,7 @@ #include "gtest/gtest.h" #include "mobile/on_vehicle_data_notification.h" -#include "utils/shared_ptr.h" + #include "utils/custom_string.h" #include "smart_objects/smart_object.h" #include "application_manager/smart_object_keys.h" @@ -61,7 +61,7 @@ using ::testing::ReturnRef; using am::commands::MessageSharedPtr; using vehicle_info_plugin::commands::OnVehicleDataNotification; -typedef ::utils::SharedPtr<OnVehicleDataNotification> NotificationPtr; +typedef std::shared_ptr<OnVehicleDataNotification> NotificationPtr; namespace { const uint32_t kAppId = 1u; diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/read_did_request_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/read_did_request_test.cc index 7cdeb2541c..c468a82bad 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/read_did_request_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/read_did_request_test.cc @@ -34,7 +34,7 @@ #include <string> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "smart_objects/smart_object.h" #include "application_manager/commands/commands_test.h" #include "application_manager/commands/command_request_test.h" @@ -62,14 +62,14 @@ namespace am = ::application_manager; using vehicle_info_plugin::commands::ReadDIDRequest; using am::commands::MessageSharedPtr; using am::event_engine::Event; -using ::utils::SharedPtr; + class ReadDIDRequestTest : public CommandRequestTest<CommandsTestMocks::kIsNice> {}; TEST_F(ReadDIDRequestTest, OnEvent_WrongEventId_UNSUCCESS) { Event event(Event::EventID::INVALID_ENUM); - SharedPtr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); + std::shared_ptr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); EXPECT_CALL(mock_rpc_service_, ManageMobileCommand(_, _)).Times(0); command->on_event(event); } @@ -77,7 +77,7 @@ TEST_F(ReadDIDRequestTest, OnEvent_WrongEventId_UNSUCCESS) { TEST_F(ReadDIDRequestTest, OnEvent_SUCCESS) { Event event(Event::EventID::VehicleInfo_ReadDID); - SharedPtr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); + std::shared_ptr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); const hmi_apis::Common_Result::eType hmi_response_code = hmi_apis::Common_Result::SUCCESS; @@ -99,10 +99,10 @@ TEST_F(ReadDIDRequestTest, OnEvent_SUCCESS) { } TEST_F(ReadDIDRequestTest, Run_AppNotRegistered_UNSUCCESS) { - SharedPtr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); + std::shared_ptr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); ON_CALL(app_mngr_, application(_)) - .WillByDefault(Return(SharedPtr<am::Application>())); + .WillByDefault(Return(std::shared_ptr<am::Application>())); MessageSharedPtr result_msg(CatchMobileCommandResult(CallRun(*command))); EXPECT_EQ(mobile_apis::Result::APPLICATION_NOT_REGISTERED, @@ -112,7 +112,7 @@ TEST_F(ReadDIDRequestTest, Run_AppNotRegistered_UNSUCCESS) { } TEST_F(ReadDIDRequestTest, Run_CommandLimitsExceeded_UNSUCCESS) { - SharedPtr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); + std::shared_ptr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); MockAppPtr app(CreateMockApp()); ON_CALL(app_mngr_, application(_)).WillByDefault(Return(app)); @@ -128,7 +128,7 @@ TEST_F(ReadDIDRequestTest, Run_CommandLimitsExceeded_UNSUCCESS) { TEST_F(ReadDIDRequestTest, Run_EmptyDidLocation_UNSUCCESS) { MockAppPtr app(CreateMockApp()); - SharedPtr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); + std::shared_ptr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>()); ON_CALL(app_mngr_, application(_)).WillByDefault(Return(app)); @@ -145,7 +145,7 @@ TEST_F(ReadDIDRequestTest, Run_SUCCESS) { MockAppPtr app(CreateMockApp()); MessageSharedPtr msg(CreateMessage(smart_objects::SmartType_Map)); (*msg)[am::strings::msg_params][am::strings::did_location]["SomeData"] = 0; - SharedPtr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>(msg)); + std::shared_ptr<ReadDIDRequest> command(CreateCommand<ReadDIDRequest>(msg)); ON_CALL(app_mngr_, application(_)).WillByDefault(Return(app)); diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_request_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_request_test.cc index 369a37e388..323334de2d 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_request_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_request_test.cc @@ -34,7 +34,7 @@ #include <string> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "application_manager/commands/command_request_test.h" #include "application_manager/mock_application_manager.h" #include "application_manager/mock_message_helper.h" @@ -56,7 +56,7 @@ using ::testing::_; using vehicle_info_plugin::commands::UnsubscribeVehicleDataRequest; using am::commands::MessageSharedPtr; -typedef ::utils::SharedPtr<UnsubscribeVehicleDataRequest> CommandPtr; +typedef std::shared_ptr<UnsubscribeVehicleDataRequest> CommandPtr; namespace { const uint32_t kConnectionKey = 1u; @@ -71,7 +71,7 @@ class UnsubscribeVehicleRequestTest UnsubscribeVehicleRequestTest() : mock_app_(CreateMockApp()) , vi_app_extension_ptr_( - utils::MakeShared<vehicle_info_plugin::VehicleInfoAppExtension>( + std::make_shared<vehicle_info_plugin::VehicleInfoAppExtension>( vi_plugin_, *mock_app_)) , app_set_lock_ptr_(std::make_shared<sync_primitives::Lock>()) {} diff --git a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_response_test.cc b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_response_test.cc index bed9cffeb2..a0d4699de8 100644 --- a/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_response_test.cc +++ b/src/components/application_manager/rpc_plugins/vehicle_info_plugin/test/commands/mobile/unsubscribe_vehicle_response_test.cc @@ -34,7 +34,7 @@ #include <stdint.h> #include <string> #include "gtest/gtest.h" -#include "utils/shared_ptr.h" + #include "application_manager/commands/commands_test.h" #include "application_manager/mock_application_manager.h" @@ -66,10 +66,10 @@ MATCHER_P(ResultCodeIs, result_code, "") { TEST_F(UnsubscribeVehicleResponseTest, Run_SendFalseResponseToMobile_SendInvalidEnum) { MessageSharedPtr command_msg = - ::utils::MakeShared<SmartObject>(smart_objects::SmartType_Map); + std::make_shared<SmartObject>(smart_objects::SmartType_Map); (*command_msg)[am::strings::msg_params][am::strings::success] = false; - ::utils::SharedPtr<UnsubscribeVehicleDataResponse> command = + std::shared_ptr<UnsubscribeVehicleDataResponse> command = CreateCommand<UnsubscribeVehicleDataResponse>(command_msg); EXPECT_CALL( @@ -81,9 +81,9 @@ TEST_F(UnsubscribeVehicleResponseTest, TEST_F(UnsubscribeVehicleResponseTest, Run_SendSuccessfulResponseToMobile_SUCCESS) { MessageSharedPtr command_msg = - ::utils::MakeShared<SmartObject>(smart_objects::SmartType_Map); + std::make_shared<SmartObject>(smart_objects::SmartType_Map); (*command_msg)[am::strings::msg_params][am::strings::success] = true; - ::utils::SharedPtr<UnsubscribeVehicleDataResponse> command = + std::shared_ptr<UnsubscribeVehicleDataResponse> command = CreateCommand<UnsubscribeVehicleDataResponse>(command_msg); EXPECT_CALL( @@ -95,13 +95,13 @@ TEST_F(UnsubscribeVehicleResponseTest, TEST_F(UnsubscribeVehicleResponseTest, Run_SendResponseToMobile_SendCodeToMobile) { MessageSharedPtr command_msg = - ::utils::MakeShared<SmartObject>(smart_objects::SmartType_Map); + std::make_shared<SmartObject>(smart_objects::SmartType_Map); (*command_msg)[am::strings::msg_params][am::strings::success] = true; mobile_apis::Result::eType result_type = mobile_apis::Result::WARNINGS; (*command_msg)[am::strings::msg_params][am::strings::result_code] = result_type; - ::utils::SharedPtr<UnsubscribeVehicleDataResponse> command = + std::shared_ptr<UnsubscribeVehicleDataResponse> command = CreateCommand<UnsubscribeVehicleDataResponse>(command_msg); command->Run(); |