# Copyright (C) 2019 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import("perfetto.gni")

perfetto_unittests_targets = [
  "gn:default_deps",
  "gn:gtest_main",
  "src/base:unittests",
  "src/protozero:unittests",
  "src/tracing:unittests",
]

if (enable_perfetto_tools && current_toolchain == host_toolchain) {
  perfetto_unittests_targets += [ "tools/ftrace_proto_gen:unittests" ]
}

# TODO(primiano): sanitizers_unittests shouldn't really be under tools. It's
# not a tool and it's intended to run on both host and targets to check that
# sanitizers are actually working.
if ((is_linux || is_android) && !perfetto_build_with_embedder) {
  # This test depends on pthread and can't run on non-Linux-based OS.
  perfetto_unittests_targets += [ "tools/sanitizers_unittests" ]
}

if (enable_perfetto_ipc) {
  perfetto_unittests_targets += [ "src/ipc:unittests" ]
}

if (enable_perfetto_platform_services) {
  perfetto_unittests_targets += [
    "src/perfetto_cmd:unittests",
    "src/traced/probes:unittests",
    "src/traced/probes/filesystem:unittests",
    "src/traced/probes/ftrace:unittests",
    "src/traced/service:unittests",
  ]
}

if (enable_perfetto_heapprofd) {
  perfetto_unittests_targets += [
    "src/profiling/memory:unittests",
    "src/profiling/memory:ring_buffer_unittests",
  ]
}

if (enable_perfetto_trace_processor) {
  perfetto_unittests_targets += [
    "src/trace_processor:unittests",
    "src/trace_processor/metrics:unittests",
  ]
}
