| # Copyright 2021 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/components.gni") |
| import("//build/fidl/fidl.gni") |
| import("//build/test.gni") |
| |
| group("dispatcher") { |
| testonly = true |
| deps = [ |
| ":fidl_llcpp_dispatcher_tests", |
| ":fidl_llcpp_endpoints_tests", |
| ":fidl_llcpp_private_intrusive_wavl_tree_tests", |
| ] |
| } |
| |
| source_set("client_test_helpers") { |
| public = [ |
| "async_loop_and_endpoints_fixture.h", |
| "client_checkers.h", |
| "fake_sequence_dispatcher.h", |
| "lsan_disabler.h", |
| "mock_client_impl.h", |
| "test_messages.h", |
| ] |
| sources = [ "fake_sequence_dispatcher.cc" ] |
| testonly = true |
| visibility = [ |
| ":*", |
| "//sdk/lib/fidl/cpp/tests/*", |
| ] |
| public_deps = [ |
| "//sdk/lib/async:async-cpp", |
| "//sdk/lib/async-testing", |
| "//sdk/lib/fidl/cpp/wire", |
| "//zircon/system/ulib/zxtest", |
| ] |
| } |
| |
| test("fidl_llcpp_dispatcher_tests_bin") { |
| output_name = "fidl_llcpp_dispatcher_tests" |
| public = [ "mock_client_impl.h" ] |
| sources = [ |
| "bind_server_overloads_test.cc", |
| "client_base_test.cc", |
| "client_continuation_test.cc", |
| "client_controller_test.cc", |
| "client_test.cc", |
| "server_binding_test.cc", |
| "server_test.cc", |
| "shared_client_test.cc", |
| "teardown_observer_test.cc", |
| "thread_checker_test.cc", |
| "transaction_tests.cc", |
| ] |
| deps = [ |
| ":client_test_helpers", |
| "//sdk/lib/async:async-cpp", |
| "//sdk/lib/async-loop", |
| "//sdk/lib/async-loop:async-loop-cpp", |
| "//sdk/lib/async-loop:async-loop-default", |
| "//sdk/testing/fidl/protocols_tests:test.basic.protocol_cpp", |
| "//sdk/testing/fidl/protocols_tests:test.empty.protocol_cpp", |
| "//src/lib/fidl/llcpp/tests/integration:fidl.test.coding.fuchsia_cpp", |
| "//zircon/system/ulib/sync:sync-cpp", |
| "//zircon/system/ulib/zxtest", |
| ] |
| } |
| |
| fuchsia_unittest_package("fidl_llcpp_dispatcher_tests") { |
| deps = [ ":fidl_llcpp_dispatcher_tests_bin" ] |
| deprecated_legacy_test_execution = true |
| } |
| |
| test("fidl_llcpp_private_intrusive_wavl_tree_tests_bin") { |
| output_name = "fidl_llcpp_private_intrusive_wavl_tree_tests" |
| sources = [ "intrusive_wavl_tree_tests.cc" ] |
| deps = [ |
| "//sdk/lib/fidl/cpp/wire", |
| "//zircon/system/ulib/fbl", |
| "//zircon/system/ulib/zxtest", |
| ] |
| } |
| |
| fuchsia_unittest_package("fidl_llcpp_private_intrusive_wavl_tree_tests") { |
| deps = [ ":fidl_llcpp_private_intrusive_wavl_tree_tests_bin" ] |
| } |
| |
| test("fidl_llcpp_endpoints_tests_bin") { |
| output_name = "fidl_llcpp_endpoints_tests" |
| sources = [ |
| "client_end_test.cc", |
| "server_end_test.cc", |
| ] |
| deps = [ |
| "//sdk/lib/async:async-cpp", |
| "//sdk/lib/async-loop", |
| "//sdk/lib/async-loop:async-loop-cpp", |
| "//sdk/lib/async-loop:async-loop-default", |
| "//src/lib/fidl/llcpp/tests/integration:llcpptest.protocol.test_cpp", |
| "//src/lib/fxl/test:gtest_main", |
| "//third_party/googletest:gtest", |
| ] |
| } |
| |
| fuchsia_unittest_package("fidl_llcpp_endpoints_tests") { |
| # Use `fuchsia.process.Launcher` for death tests |
| manifest = "meta/endpoints_tests.cml" |
| deps = [ ":fidl_llcpp_endpoints_tests_bin" ] |
| } |