xref: /aosp_15_r20/external/perfetto/gn/perfetto_integrationtests.gni (revision 6dbdd20afdafa5e3ca9b8809fa73465d530080dc)
1*6dbdd20aSAndroid Build Coastguard Worker# Copyright (C) 2019 The Android Open Source Project
2*6dbdd20aSAndroid Build Coastguard Worker#
3*6dbdd20aSAndroid Build Coastguard Worker# Licensed under the Apache License, Version 2.0 (the "License");
4*6dbdd20aSAndroid Build Coastguard Worker# you may not use this file except in compliance with the License.
5*6dbdd20aSAndroid Build Coastguard Worker# You may obtain a copy of the License at
6*6dbdd20aSAndroid Build Coastguard Worker#
7*6dbdd20aSAndroid Build Coastguard Worker#      http://www.apache.org/licenses/LICENSE-2.0
8*6dbdd20aSAndroid Build Coastguard Worker#
9*6dbdd20aSAndroid Build Coastguard Worker# Unless required by applicable law or agreed to in writing, software
10*6dbdd20aSAndroid Build Coastguard Worker# distributed under the License is distributed on an "AS IS" BASIS,
11*6dbdd20aSAndroid Build Coastguard Worker# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12*6dbdd20aSAndroid Build Coastguard Worker# See the License for the specific language governing permissions and
13*6dbdd20aSAndroid Build Coastguard Worker# limitations under the License.
14*6dbdd20aSAndroid Build Coastguard Worker
15*6dbdd20aSAndroid Build Coastguard Workerimport("perfetto.gni")
16*6dbdd20aSAndroid Build Coastguard Worker
17*6dbdd20aSAndroid Build Coastguard Workerperfetto_integrationtests_targets = [
18*6dbdd20aSAndroid Build Coastguard Worker  "src/tracing/test:client_api_integrationtests",
19*6dbdd20aSAndroid Build Coastguard Worker  "src/shared_lib/test:integrationtests",
20*6dbdd20aSAndroid Build Coastguard Worker]
21*6dbdd20aSAndroid Build Coastguard Worker
22*6dbdd20aSAndroid Build Coastguard Workerif (enable_perfetto_ipc && enable_perfetto_system_consumer) {
23*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets += [
24*6dbdd20aSAndroid Build Coastguard Worker    "src/tracing/test:tracing_integration_test",
25*6dbdd20aSAndroid Build Coastguard Worker    "src/tracing:integrationtests",
26*6dbdd20aSAndroid Build Coastguard Worker  ]
27*6dbdd20aSAndroid Build Coastguard Worker}
28*6dbdd20aSAndroid Build Coastguard Worker
29*6dbdd20aSAndroid Build Coastguard Workerif (enable_perfetto_traced_probes) {
30*6dbdd20aSAndroid Build Coastguard Worker  # enable_perfetto_traced_probes implies enable_perfetto_platform_services.
31*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets += [
32*6dbdd20aSAndroid Build Coastguard Worker    "src/traced/probes/ftrace:integrationtests",
33*6dbdd20aSAndroid Build Coastguard Worker    "test:perfetto_end_to_end_integrationtests",
34*6dbdd20aSAndroid Build Coastguard Worker  ]
35*6dbdd20aSAndroid Build Coastguard Worker}
36*6dbdd20aSAndroid Build Coastguard Worker
37*6dbdd20aSAndroid Build Coastguard Workerif (enable_perfetto_heapprofd) {
38*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets +=
39*6dbdd20aSAndroid Build Coastguard Worker      [ "src/profiling/memory:end_to_end_tests" ]
40*6dbdd20aSAndroid Build Coastguard Worker}
41*6dbdd20aSAndroid Build Coastguard Worker
42*6dbdd20aSAndroid Build Coastguard Worker# This test requires extra data files that are not easily available in Android
43*6dbdd20aSAndroid Build Coastguard Worker# builds.
44*6dbdd20aSAndroid Build Coastguard Worker# TODO(lalitm): looks like they don't work on standalone Android either because
45*6dbdd20aSAndroid Build Coastguard Worker# run_android_test doesn't push the test data.
46*6dbdd20aSAndroid Build Coastguard Workerif (enable_perfetto_trace_processor && perfetto_build_standalone &&
47*6dbdd20aSAndroid Build Coastguard Worker    !is_android) {
48*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets +=
49*6dbdd20aSAndroid Build Coastguard Worker      [ "src/trace_processor:integrationtests" ]
50*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets += [ "src/traceconv:integrationtests" ]
51*6dbdd20aSAndroid Build Coastguard Worker}
52*6dbdd20aSAndroid Build Coastguard Worker
53*6dbdd20aSAndroid Build Coastguard Worker# This test requires traces that are not available on Android builds.
54*6dbdd20aSAndroid Build Coastguard Workerif (perfetto_build_standalone && !is_android) {
55*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets +=
56*6dbdd20aSAndroid Build Coastguard Worker      [ "src/trace_redaction:integrationtests" ]
57*6dbdd20aSAndroid Build Coastguard Worker}
58*6dbdd20aSAndroid Build Coastguard Worker
59*6dbdd20aSAndroid Build Coastguard Workerif (enable_perfetto_traced_relay) {
60*6dbdd20aSAndroid Build Coastguard Worker  perfetto_integrationtests_targets += [ "src/traced_relay:integrationtests" ]
61*6dbdd20aSAndroid Build Coastguard Worker}
62