• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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")
15import("//foundation/multimedia/player_framework/config.gni")
16
17module_output_path = "multimedia_player_framework/player"
18
19ohos_unittest("player_unit_test") {
20  module_out_path = module_output_path
21  include_dirs = [
22    "./include",
23    "//foundation/multimedia/player_framework/interfaces/inner_api/native",
24    "//foundation/multimedia/player_framework/frameworks/native/player",
25    "//graphic/graphic_2d/interfaces/innerkits/surface",
26    "//foundation/window/window_manager/interfaces/innerkits/wm",
27    "//foundation/multimedia/player_framework/test/unittest/common/include",
28    "src/data_source",
29  ]
30
31  cflags = [
32    "-Wall",
33    "-Werror",
34    "-Wno-deprecated-declarations",
35  ]
36
37  if (multimedia_player_framework_support_player) {
38    sources = [
39      "src/data_source/media_data_source_test_noseek.cpp",
40      "src/data_source/media_data_source_test_seekable.cpp",
41      "src/player_mock.cpp",
42      "src/player_unit_test.cpp",
43    ]
44  }
45
46  deps = [
47    "//foundation/graphic/graphic_2d:libsurface",
48    "//foundation/graphic/graphic_2d/frameworks/surface:surface",
49    "//foundation/graphic/graphic_2d/rosen/modules/render_service_client:librender_service_client",
50    "//foundation/multimedia/player_framework/interfaces/inner_api/native:media_client",
51    "//foundation/window/window_manager/wm:libwm",
52  ]
53
54  resource_config_file = "//foundation/multimedia/player_framework/test/unittest/resources/ohos_test.xml"
55}
56