Remove app event dependency 82/308682/1
authorIlho Kim <ilho159.kim@samsung.com>
Fri, 29 Mar 2024 00:07:49 +0000 (09:07 +0900)
committerIlho Kim <ilho159.kim@samsung.com>
Fri, 29 Mar 2024 00:07:49 +0000 (09:07 +0900)
Being dependent on app event makes dependent on app-core-ui,efl
it causes a lack of capacity in the headless image

Change-Id: Ie8135295d59d1bb9935648a9d8fdeb5dc3e78f39
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
CMakeLists.txt
client/CMakeLists.txt
installer/CMakeLists.txt
packaging/pkgmgr.spec
test/unit_tests/CMakeLists.txt
test/unit_tests/mock/app_event_mock.cc [deleted file]
test/unit_tests/mock/app_event_mock.hh [deleted file]
test/unit_tests/test_client.cc

index 2cbea2f..51d0da6 100644 (file)
@@ -24,7 +24,6 @@ PKG_CHECK_MODULES(GMOCK_DEPS REQUIRED gmock)
 PKG_CHECK_MODULES(GLIB_DEPS REQUIRED glib-2.0)
 PKG_CHECK_MODULES(GIO_DEPS REQUIRED gio-2.0)
 PKG_CHECK_MODULES(RPC_PORT_DEPS REQUIRED rpc-port)
-PKG_CHECK_MODULES(CAPI_APPFW_EVENT_DEPS REQUIRED capi-appfw-event)
 PKG_CHECK_MODULES(PKGMGR_PARSER_DEPS REQUIRED pkgmgr-parser)
 PKG_CHECK_MODULES(PKGMGR_INFO_DEPS REQUIRED pkgmgr-info)
 PKG_CHECK_MODULES(INIPARSER_DEPS REQUIRED iniparser)
index fe06c79..e97eb4f 100644 (file)
@@ -21,7 +21,6 @@ APPLY_PKG_CONFIG(${PKGMGR_CLIENT} PUBLIC
   PLATFORM_CONFIG_DEPS
   MINIZIP_DEPS
   RPC_PORT_DEPS
-  CAPI_APPFW_EVENT_DEPS
 )
 TARGET_LINK_LIBRARIES(${PKGMGR_CLIENT} PUBLIC "dl")
 
index d0289b1..a27b9f7 100644 (file)
@@ -9,7 +9,6 @@ PKG_CHECK_MODULES(INSTALLER_DEPS REQUIRED
   pkgmgr-info
   libtzplatform-config
   rpc-port
-  capi-appfw-event
 )
 
 FOREACH(FLAGS ${INSTALLER_DEPS_CFLAGS})
index b0c2c50..88bcd93 100644 (file)
@@ -33,7 +33,6 @@ BuildRequires:  pkgconfig(libsmack)
 BuildRequires:  pkgconfig(libsystemd)
 BuildRequires:  pkgconfig(minizip)
 BuildRequires:  pkgconfig(rpc-port)
-BuildRequires:  pkgconfig(capi-appfw-event)
 BuildRequires:  pkgconfig(gmock)
 BuildRequires:  pkgmgr-info-parser-devel
 BuildRequires:  pkgmgr-info-parser
index d328392..967dec9 100644 (file)
@@ -18,7 +18,6 @@ APPLY_PKG_CONFIG(${TARGET_PKGMGR_UNIT_TEST} PUBLIC
   GMOCK_DEPS
   GLIB_DEPS
   RPC_PORT_DEPS
-  CAPI_APPFW_EVENT_DEPS
   DLOG_DEPS
   BUNDLE_DEPS
 )
diff --git a/test/unit_tests/mock/app_event_mock.cc b/test/unit_tests/mock/app_event_mock.cc
deleted file mode 100644 (file)
index 165caa3..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) 2022 Samsung Electronics Co., Ltd.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#include "mock/app_event_mock.hh"
-#include "mock/mock_hook.hh"
-#include "mock/test_fixture.hh"
-
-extern "C" int event_add_event_handler(const char *event_name,
-    event_cb callback, void *user_data, event_handler_h *event_handler) {
-  return MOCK_HOOK_P4(AppEventMock, event_add_event_handler,
-      event_name, callback, user_data, event_handler);
-}
-
-extern "C" int event_remove_event_handler(event_handler_h event_handler) {
-  return MOCK_HOOK_P1(AppEventMock, event_remove_event_handler,
-      event_handler);
-}
-
-extern "C" int event_publish_app_event(const char *event_name,
-    bundle *event_data) {
-  return MOCK_HOOK_P2(AppEventMock, event_publish_app_event,
-      event_name, event_data);
-}
diff --git a/test/unit_tests/mock/app_event_mock.hh b/test/unit_tests/mock/app_event_mock.hh
deleted file mode 100644 (file)
index fe6af4b..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (c) 2022 Samsung Electronics Co., Ltd.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef UNIT_TESTS_MOCK_APP_EVENT_MOCK_HH_
-#define UNIT_TESTS_MOCK_APP_EVENT_MOCK_HH_
-
-#include <app_event.h>
-#include <gmock/gmock.h>
-
-#include "mock/module_mock.hh"
-
-class AppEventMock : public virtual ModuleMock {
- public:
-  AppEventMock() {}
-  virtual ~AppEventMock() {}
-
-  MOCK_METHOD(int, event_add_event_handler, (const char*,
-      event_cb, void*, event_handler_h*));
-  MOCK_METHOD(int, event_remove_event_handler, (event_handler_h));
-  MOCK_METHOD(int, event_publish_app_event, (const char*, bundle*));
-};
-
-#endif  // UNIT_TESTS_MOCK_APP_EVENT_MOCK_HH_
index c5fb6e7..b8c44ee 100644 (file)
@@ -4,15 +4,13 @@
 #include <gmock/gmock.h>
 
 #include "unit_tests/mock/rpc_port_mock.hh"
-#include "unit_tests/mock/app_event_mock.hh"
 #include "unit_tests/mock/test_fixture.hh"
 
 using ::testing::_;
 using ::testing::Invoke;
 
 namespace {
-class Mocks : public ::testing::NiceMock<RpcPortMock>,
-    virtual public ::testing::NiceMock<AppEventMock> {};
+class Mocks : public ::testing::NiceMock<RpcPortMock> {};
 
 }  // namespace