# Copyright (C) 2022 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("//build/ohos.gni") import("//build/ohos_var.gni") import("//build/test.gni") import("//foundation/resourceschedule/frame_aware_sched/frameaware.gni") module_output_path = "frameawareschedtest/" frame_aware_sched_configs = [ "${innerkits_path}/frameintf:frame_msg_intf_config" ] frame_aware_sched_deps = [ "${innerkits_path}/frameintf:frame_msg_intf" ] frame_aware_sched_public_deps = [ "//third_party/googletest:gtest_main" ] ohos_unittest("frame_ui_intf_test") { module_out_path = module_output_path configs = frame_aware_sched_configs sources = [ "unittest/phone/frame_ui_intf_test.cpp" ] if (is_standard_system) { public_deps = frame_aware_sched_public_deps } part_name = "frame_aware_sched" subsystem_name = "resourceschedule" } ohos_unittest("frame_msg_intf_test") { module_out_path = module_output_path sources = [ "unittest/phone/frame_msg_intf_test.cpp" ] include_dirs = [ "//base/hiviewdfx/hiview/adapter/utility/include/extra/", "//base/notification/eventhandler/interfaces/inner_api/", ] configs = frame_aware_sched_configs if (is_standard_system) { public_deps = frame_aware_sched_public_deps } part_name = "frame_aware_sched" subsystem_name = "resourceschedule" } ohos_unittest("rtg_interface_test") { module_out_path = module_output_path sources = [ "unittest/phone/rtg_interface_test.cpp" ] include_dirs = [ "${frame_aware_path}/common/include" ] deps = frame_aware_sched_deps if (is_standard_system) { public_deps = frame_aware_sched_public_deps } part_name = "frame_aware_sched" subsystem_name = "resourceschedule" } group("frame_unittest") { testonly = true deps = [] if (!is_asan) { deps += [ ":frame_msg_intf_test", ":rtg_interface_test", ] } }