blob: 53efd8a1cd259c39a8c4ade2c8d304c370d4264e [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/cpp/sdk_source_set.gni")
import("//build/fidl/fidl.gni")
import("//build/package.gni")
import("//build/test/test_package.gni")
group("unittests") {
testonly = true
deps = [
":test_harness_impl_unittest",
]
}
source_set("test_harness_fixture") {
testonly = true
public_configs = [ "//sdk/config" ]
sources = [
"fake_agent.cc",
"fake_agent.h",
"fake_component.cc",
"fake_component.h",
"fake_module.cc",
"fake_module.h",
"fake_session_shell.cc",
"fake_session_shell.h",
"fake_story_shell.cc",
"fake_story_shell.h",
"test_harness_fixture.cc",
"test_harness_fixture.h",
]
public_deps = [
"//sdk/lib/modular/testing/cpp",
]
deps = [
"//garnet/public/lib/svc/cpp",
"//peridot/lib/testing:session_shell_impl",
"//sdk/fidl/fuchsia.modular.testing",
"//sdk/lib/sys/cpp",
"//sdk/lib/sys/cpp/testing:integration",
"//third_party/googletest:gtest",
]
}
executable("test_harness_fixture_test_bin") {
testonly = true
sources = [
"test_harness_fixture_test.cc",
]
deps = [
":test_harness_fixture",
"//garnet/public/lib/fsl",
"//sdk/fidl/fuchsia.modular.testing",
"//sdk/fidl/fuchsia.sys",
"//sdk/lib/sys/cpp",
"//sdk/lib/sys/cpp/testing:integration",
"//sdk/lib/sys/cpp/testing:unit",
"//src/lib/fxl/test:gtest_main",
"//third_party/googletest:gmock",
]
}
test_package("test_harness_fixture_test") {
deprecated_shell = "//build"
tests = [
{
name = "test_harness_fixture_test_bin"
# TODO(FLK-410): deflake and reenable this test.
disabled = true
environments = basic_envs
},
]
deps = [
":test_harness_fixture_test_bin",
]
}
source_set("test_harness_impl") {
testonly = true
sources = [
"test_harness_impl.cc",
"test_harness_impl.h",
]
public_deps = [
"//garnet/public/lib/fsl",
"//garnet/public/lib/fxl",
"//peridot/lib/modular_config",
"//peridot/public/lib/app_driver/cpp:agent_driver",
"//sdk/fidl/fuchsia.auth.account",
"//sdk/fidl/fuchsia.devicesettings",
"//sdk/fidl/fuchsia.modular",
"//sdk/fidl/fuchsia.modular.testing",
"//sdk/fidl/fuchsia.setui",
"//sdk/fidl/fuchsia.sys",
"//sdk/lib/sys/cpp/testing:enclosing_environment",
"//zircon/public/lib/async-loop-cpp",
]
deps = [
"//peridot/lib/fidl:json_xdr",
"//peridot/lib/modular_config:json_xdr",
"//peridot/lib/util:pseudo_dir_utils",
]
}
source_set("test_harness_impl_unittest") {
testonly = true
sources = [
"test_harness_impl_unittest.cc",
]
deps = [
":test_harness_impl",
"//peridot/lib/modular_config",
"//peridot/lib/rapidjson",
"//peridot/lib/util:pseudo_dir_server",
"//sdk/fidl/fuchsia.modular",
"//sdk/fidl/fuchsia.modular.testing",
"//sdk/lib/sys/cpp/testing:integration",
"//sdk/lib/sys/cpp/testing:unit",
"//src/lib/fxl/test:gtest_main",
"//zircon/public/lib/fidl",
]
}