1# Copyright (c) 2022 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14import("//build/test.gni") 15 16module_output_path = "neural_network_runtime/" 17 18config("module_private_config") { 19 visibility = [ ":*" ] 20 21 include_dirs = [ 22 "//third_party/googletest/googlemock/include", 23 "//foundation/ai/neural_network_runtime", 24 "//foundation/communication/ipc/interfaces/innerkits/ipc_core/include", 25 "//third_party/mindspore/mindspore/lite/mindir/include" 26 ] 27 28 cflags = [ 29 "-Wall", 30 "-Wextra", 31 "-Werror", 32 "--coverage", 33 ] 34 35 ldflags = [ 36 "--coverage", 37 ] 38} 39 40ohos_unittest("NeuralNetworkRuntimeInnerTest") { 41 module_out_path = module_output_path 42 sources = ["//foundation/ai/neural_network_runtime/test/unittest/inner_kits/neural_network_runtime_inner_test.cpp"] 43 44 configs = [ ":module_private_config" ] 45 46 deps = [ 47 "//foundation/ai/neural_network_runtime/frameworks:libneural_network_runtime", 48 "//third_party/googletest:gtest_main", 49 ] 50 51 external_deps = [ 52 "hitrace_native:libhitracechain", 53 "hiviewdfx_hilog_native:libhilog", 54 "drivers_interface_nnrt:libnnrt_proxy_1.0", 55 "c_utils:utils", 56 "hdf_core:libhdf_utils", 57 "mindspore:mindir" 58 ] 59} 60 61group("inner_kits_unittest") { 62 testonly = true 63 deps = [ ":NeuralNetworkRuntimeInnerTest" ] 64} 65