summaryrefslogtreecommitdiff
path: root/src/components
diff options
context:
space:
mode:
authorKozoriz <kozorizandriy@gmail.com>2016-02-29 10:43:40 +0200
committerKozoriz <kozorizandriy@gmail.com>2016-03-04 10:11:53 +0200
commitf42d358711ba06360131a5c3ac7621b5bec1fcda (patch)
treed4ab8c1cc8fbfe44576aec68449b9705878603b0 /src/components
parent313af5af834d4ef09e0acadb03733e3d80678d4c (diff)
downloadsdl_core-f42d358711ba06360131a5c3ac7621b5bec1fcda.tar.gz
Correctives in SecurityManager and TimeTester
Corrected tests after removing ConnectionHandler, ProtocolHandler, HMIMessageHandler singletones. Related to : APPLINK-21440
Diffstat (limited to 'src/components')
-rw-r--r--src/components/security_manager/test/security_manager_test.cc2
-rw-r--r--src/components/time_tester/test/CMakeLists.txt10
-rw-r--r--src/components/time_tester/test/time_manager_test.cc24
3 files changed, 24 insertions, 12 deletions
diff --git a/src/components/security_manager/test/security_manager_test.cc b/src/components/security_manager/test/security_manager_test.cc
index f516db1159..4d94367ee7 100644
--- a/src/components/security_manager/test/security_manager_test.cc
+++ b/src/components/security_manager/test/security_manager_test.cc
@@ -39,7 +39,7 @@
#include "protocol_handler/mock_protocol_handler.h"
#include "protocol_handler/mock_session_observer.h"
-#include "transport_manager_mock.h"
+#include "transport_manager/transport_manager_mock.h"
#include "security_manager/mock_security_manager.h"
#include "security_manager/mock_ssl_context.h"
#include "security_manager/mock_crypto_manager.h"
diff --git a/src/components/time_tester/test/CMakeLists.txt b/src/components/time_tester/test/CMakeLists.txt
index 4f83e6597a..360d85239d 100644
--- a/src/components/time_tester/test/CMakeLists.txt
+++ b/src/components/time_tester/test/CMakeLists.txt
@@ -58,21 +58,21 @@ set(testLibraries
gmock
TimeTester
jsoncpp
- Utils
+ Utils
MediaManager
- ProtocolHandler
+ ProtocolHandler
v4_protocol_v1_2_no_extra
- SmartObjects
+ SmartObjects
ProtocolLibrary
ConfigProfile
- connectionHandler
ApplicationManager
MessageHelper
Resumption
jsoncpp
transport_manager
MediaManager
- ProtocolHandler
+ ProtocolHandler
+ connectionHandler
)
if (BUILD_USB_SUPPORT)
diff --git a/src/components/time_tester/test/time_manager_test.cc b/src/components/time_tester/test/time_manager_test.cc
index c5ad607a97..1d34656fde 100644
--- a/src/components/time_tester/test/time_manager_test.cc
+++ b/src/components/time_tester/test/time_manager_test.cc
@@ -31,11 +31,14 @@
*/
#include "gtest/gtest.h"
-#include "gmock/gmock.h"
-#include "time_manager.h"
+#include "time_tester/time_manager.h"
#include "protocol_handler/time_metric_observer.h"
-#include "protocol_handler.h"
-#include "include/protocol_handler_mock.h"
+#include "protocol_handler/protocol_handler.h"
+#include "protocol_handler//mock_protocol_handler.h"
+#include "protocol_handler/mock_session_observer.h"
+#include "protocol_handler/mock_protocol_handler_settings.h"
+#include "connection_handler/mock_connection_handler.h"
+#include "transport_manager/transport_manager_mock.h"
namespace test {
namespace components {
@@ -54,8 +57,17 @@ class StreamerMock : public Streamer {
TEST(TimeManagerTest, DISABLED_MessageProcess) {
//TODO(AK) APPLINK-13351 Disable due to refactor TimeTester
- protocol_handler_test::TransportManagerMock transport_manager_mock;
- protocol_handler::ProtocolHandlerImpl protocol_handler_mock(&transport_manager_mock, 0, 0, 0, 0, 0, 0);
+ transport_manager_test::TransportManagerMock transport_manager_mock;
+ testing::NiceMock<connection_handler_test::MockConnectionHandler>
+ connection_handler_mock;
+ test::components::protocol_handler_test::MockProtocolHandlerSettings
+ protocol_handler_settings_mock;
+ test::components::protocol_handler_test::MockSessionObserver
+ session_observer_mock;
+ protocol_handler::ProtocolHandlerImpl protocol_handler_mock(protocol_handler_settings_mock,
+ session_observer_mock,
+ connection_handler_mock,
+ transport_manager_mock);
TimeManager * time_manager = new TimeManager();
// Streamer will be deleted by Thread
StreamerMock* streamer_mock = new StreamerMock(time_manager);