1# Copyright (c) 2023 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("//test/xts/tools/build/suite.gni")
15module_output_path = "acts/nnrt"
16
17config("nncore_config") {
18  include_dirs = [
19    "../common",
20    "../../../../../../foundation/ai/neural_network_runtime",
21    "//foundation/ai/neural_network_runtime/frameworks/native/neural_network_runtime",
22    "//foundation/ai/neural_network_runtime/frameworks/native/neural_network_core",
23    "//third_party/mindspore/mindspore-src/source/mindspore/lite/mindir/include",
24  ]
25  cflags = [ "-Wno-error" ]
26  cflags_cc = [ "-fexceptions" ]
27}
28
29ohos_moduletest_suite("ActsNnrtE2ETest") {
30  module_out_path = module_output_path
31  sources = [
32    "../common/mock_idevice.cpp",
33    "../common/nncore_utils.cpp",
34    "src/EndToEndTest.cpp",
35  ]
36
37  configs = [ ":nncore_config" ]
38
39  deps = [
40    "//third_party/googletest:gmock",
41    "//third_party/googletest:gtest",
42  ]
43
44  external_deps = [
45    "c_utils:utils",
46    "drivers_interface_nnrt:libnnrt_proxy_2.0",
47    "hilog:libhilog",
48    "ipc:ipc_single",
49    "mindspore:mindir",
50    "neural_network_runtime:nnrt_target",
51  ]
52
53  subsystem_name = "ai"
54  part_name = "neural_network_runtime"
55}
56