# Copyright (c) 2024 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/appspawn/appspawn.gni") import("//build/test.gni") if (!defined(ohos_lite)) { ohos_unittest("DevicedebugTest") { module_out_path = "${module_output_path}" cflags = [ "-Wno-implicit-fallthrough", "-Wno-unused-function", "-Dprivate=public", "-Dprotected=public", ] cflags_cc = [ "-Wno-implicit-fallthrough", "-fexceptions", ] include_dirs = [ "${appspawn_path}/service/devicedebug/base", "${appspawn_path}/service/devicedebug/kill/include", "${appspawn_path}/test/unittest/devicedebug_test", ] sources = [ "${appspawn_path}/service/devicedebug/kill/src/devicedebug_kill.c", "${appspawn_path}/test/unittest/devicedebug_test/devicedebug_stub.c", "devicedebug_kill_test.cpp", ] defines = [ "IsDeveloperModeOpen=IsDeveloperModeOpenStub", "AppSpawnClientInit=AppSpawnClientInitStub", "AppSpawnReqMsgCreate=AppSpawnReqMsgCreateStub", "AppSpawnReqMsgAddExtInfo=AppSpawnReqMsgAddExtInfoStub", "AppSpawnClientSendMsg=AppSpawnClientSendMsgStub", "APPSPAWN_TEST", ] external_deps = [ "cJSON:cjson", "hilog:libhilog", ] deps = [ "${appspawn_path}/interfaces/innerkits/client:appspawn_client", "${appspawn_path}/service/devicedebug:devicedebug", "${appspawn_path}/util:libappspawn_util", ] } }