# Copyright (c) 2020-2021 Huawei Device 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. import("//base/startup/init/begetd.gni") import("//build/ohos.gni") import("//build/test.gni") ohos_shared_library("libparamtestmodule") { sources = [ "param_test_module.c" ] include_dirs = [ "//base/startup/init/services/include/param", "//base/startup/init/services/include", "//base/startup/init/services/init/include", "//base/startup/init/services/log", "//base/startup/init/interfaces/innerkits/include", "//base/startup/init/services/loopevent/include", "//base/startup/init/ueventd/include", "//third_party/cJSON", "//third_party/bounds_checking_function/include", ] deps = [ "//base/startup/init/interfaces/innerkits:libbegetutil", "//base/startup/init/services/log:agent_log", "//third_party/bounds_checking_function:libsec_shared", ] external_deps = [ "init:libinit_module_engine" ] part_name = "init" subsystem_name = "startup" module_install_dir = "lib/init" } ohos_moduletest("InitModuleTest") { module_out_path = "startup/init" sources = [ "hookmgr_moduletest.cpp", "modulemgr_moduletest.cpp", "service_control_test.cpp", "service_watcher_moduleTest.cpp", "syspara_moduleTest.cpp", "test_utils.cpp", ] include_dirs = [ "//base/startup/init/interfaces/innerkits/include", "//base/startup/init/interfaces/innerkits/include/syspara", "//base/startup/init/interfaces/innerkits/syspara", "//base/startup/init/services/include/param", ".", ] deps = [ "//base/startup/init/interfaces/innerkits:libbeget_proxy", "//base/startup/init/interfaces/innerkits:libbegetutil", "//third_party/bounds_checking_function:libsec_shared", "//third_party/googletest:gtest_main", ] } group("moduletest") { testonly = true deps = [ ":InitModuleTest" ] } group("paramtestmodule") { if (param_test) { deps = [ ":libparamtestmodule" ] } }