blob: 5cdbeb252ca678a68cdc940359442616800a74ff [file] [log] [blame]
# Copyright 2019 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/test/test_package.gni")
# This source set contains a broad variety of test-related classes.
source_set("test") {
testonly = true
public_deps = [
":constants",
":hermetic_audio_test",
":message_transceiver",
":null_renderer_capturer",
":test_fixture",
]
}
source_set("test_fixture") {
testonly = true
sources = [
"test_fixture.cc",
"test_fixture.h",
]
public_deps = [
"//garnet/public/lib/gtest",
"//sdk/lib/fidl/cpp",
"//zircon/public/lib/fit",
]
}
# Constants used by both non-hermetic and hermetic base classes
source_set("constants") {
testonly = true
sources = [ "constants.h" ]
public_deps = [ "//sdk/fidl/fuchsia.media" ]
}
# Base class for hermetic test cases
source_set("hermetic_audio_test") {
testonly = true
sources = [
"capturer_shim.h",
"comparators.cc",
"comparators.h",
"hermetic_audio_environment.cc",
"hermetic_audio_environment.h",
"hermetic_audio_test.cc",
"hermetic_audio_test.h",
"renderer_shim.cc",
"renderer_shim.h",
"virtual_device.cc",
"virtual_device.h",
]
public_deps = [
":constants",
":test_fixture",
"//sdk/fidl/fuchsia.media",
"//sdk/fidl/fuchsia.media.audio",
"//sdk/fidl/fuchsia.ultrasound",
"//sdk/fidl/fuchsia.virtualaudio",
"//sdk/lib/sys/cpp",
"//sdk/lib/sys/cpp/testing:integration",
"//sdk/lib/sys/inspect/cpp",
"//sdk/lib/syslog/cpp",
"//src/media/audio/audio_core:audio_core_lib",
"//src/media/audio/lib/analysis",
"//src/media/audio/lib/clock",
"//src/media/audio/lib/format",
"//src/media/audio/lib/logging",
"//src/media/audio/lib/wav",
"//src/power/fidl/testing:test.thermal",
"//third_party/googletest:gtest",
"//zircon/system/ulib/inspect",
]
deps = [
"//sdk/fidl/fuchsia.media.tuning",
"//sdk/fidl/fuchsia.scheduler",
"//sdk/fidl/fuchsia.scheduler",
"//src/lib/fxl",
]
# TODO(fxbug.dev/58162): delete the below and fix compiler warnings
configs += [ "//build/config:Wno-conversion" ]
}
# Main entry point for tests that use hermetic_pipeline_test.h.
source_set("hermetic_pipeline_test_main") {
testonly = true
sources = [
"hermetic_fidelity_frequencies.cc",
"hermetic_fidelity_test.cc",
"hermetic_fidelity_test.h",
"hermetic_golden_test.cc",
"hermetic_golden_test.h",
"hermetic_impulse_test.cc",
"hermetic_impulse_test.h",
"hermetic_pipeline_test.cc",
"hermetic_pipeline_test.h",
"hermetic_pipeline_test_main.cc",
]
deps = [
"//sdk/fidl/fuchsia.media",
"//src/lib/fxl",
"//src/lib/fxl/test:test_settings",
]
public_deps = [ ":hermetic_audio_test" ]
}
# Flexible utility class for channel-based communication (such as to drivers or device services).
source_set("message_transceiver") {
sources = [
"message_transceiver.cc",
"message_transceiver.h",
]
deps = [
"//sdk/lib/syslog/cpp",
"//zircon/public/lib/async-cpp",
]
# TODO(fxbug.dev/58162): delete the below and fix compiler warnings
configs += [ "//build/config:Wno-conversion" ]
}
# Empty renderer and capturer implementations suitable for use in unit testing.
source_set("null_renderer_capturer") {
sources = [
"null_audio_capturer.h",
"null_audio_renderer.h",
]
deps = [ "//sdk/fidl/fuchsia.media" ]
}