1# Copyright (c) 2022-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("//foundation/arkui/ace_engine/test/unittest/ace_unittest.gni")
15
16ace_unittest("event_manager_test_ng") {
17  type = "new"
18  module_output = "events"
19  flutter_skia = true
20  render = true
21  sources = [
22    "$ace_root/frameworks/core/event/mouse_event.cpp",
23    "$ace_root/frameworks/core/gestures/gesture_referee.cpp",
24    "$ace_root/test/mock/adapter/mock_input_manager.cpp",
25    "$ace_root/test/mock/core/common/mock_watch_dog.cpp",
26    "$ace_root/test/mock/core/common/mock_window.cpp",
27    "event_dump_test_ng.cpp",
28    "event_manager_test_ng.cpp",
29    "event_manager_test_ng_new.cpp",
30  ]
31}
32
33ace_unittest("click_event_test_ng") {
34  module_output = "events"
35  type = "new"
36  sources = [ "click_event_test_ng.cpp" ]
37}
38
39ace_unittest("drag_event_test_ng") {
40  type = "new"
41  module_output = "events"
42  sources = [
43    "drag_event_test_ng.cpp",
44    "drag_event_test_ng_property_config.cpp",
45    "drag_event_test_ng_property_config_coverage.cpp",
46  ]
47}
48
49ace_unittest("event_hub_test_ng") {
50  type = "new"
51  module_output = "events"
52  sources = [ "event_hub_test_ng.cpp" ]
53}
54
55ace_unittest("focus_hub_test_ng") {
56  type = "new"
57  module_output = "events"
58  sources = [
59    "focus_hub_test_ng.cpp",
60    "focus_hub_test_ng_branch_coverage.cpp",
61    "focus_hub_test_ng_for_property_config.cpp",
62    "focus_hub_test_ng_new.cpp",
63  ]
64}
65
66ace_unittest("gesture_event_hub_test_ng") {
67  type = "new"
68  module_output = "events"
69  sources = [
70    "gesture_event_hub_test_ng.cpp",
71    "gesture_event_hub_test_ng_coverage.cpp",
72    "gesture_event_hub_test_ng_property_config.cpp",
73    "gesture_event_hub_test_two_ng.cpp",
74  ]
75}
76
77ace_unittest("input_event_hub_test_ng") {
78  type = "new"
79  module_output = "events"
80  sources = [
81    "$ace_root/frameworks/core/event/mouse_event.cpp",
82    "input_event_hub_test_ng.cpp",
83  ]
84}
85
86ace_unittest("long_press_event_test_ng") {
87  module_output = "events"
88  type = "new"
89  sources = [ "long_press_event_test_ng.cpp" ]
90}
91
92ace_unittest("pan_event_test_ng") {
93  type = "new"
94  module_output = "events"
95  sources = [ "pan_event_test_ng.cpp" ]
96}
97
98ace_unittest("scrollable_event_test_ng") {
99  type = "new"
100  module_output = "events"
101  sources = [ "scrollable_event_test_ng.cpp" ]
102}
103
104ace_unittest("state_style_test_ng") {
105  type = "new"
106  module_output = "events"
107  sources = [ "state_style_manager_test_ng.cpp" ]
108}
109
110ace_unittest("touch_event_test_ng") {
111  type = "new"
112  module_output = "events"
113  sources = [ "touch_event_test_ng.cpp" ]
114}
115
116ace_unittest("response_ctrl_test_ng") {
117  type = "new"
118  module_output = "events"
119  sources = [ "response_ctrl_test_ng.cpp" ]
120}
121
122ace_unittest("input_event_test_ng") {
123  type = "new"
124  module_output = "events"
125  sources = [ "input_event_test_ng.cpp" ]
126}
127
128ace_unittest("focus_box_test_ng") {
129  type = "new"
130  module_output = "events"
131  sources = [ "focus_box_test_ng.cpp" ]
132}
133
134group("core_event_unittest") {
135  testonly = true
136  deps = [
137    ":click_event_test_ng",
138    ":drag_event_test_ng",
139    ":event_hub_test_ng",
140    ":event_manager_test_ng",
141    ":focus_box_test_ng",
142    ":focus_hub_test_ng",
143    ":gesture_event_hub_test_ng",
144    ":input_event_hub_test_ng",
145    ":input_event_test_ng",
146    ":long_press_event_test_ng",
147    ":pan_event_test_ng",
148    ":response_ctrl_test_ng",
149    ":scrollable_event_test_ng",
150    ":state_style_test_ng",
151    ":touch_event_test_ng",
152  ]
153}
154