blob: 093ad3cf4303687286f77ea7107b3f7217fbf5dd [file]
# 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("//src/sys/build/components.gni")
###############################################################################
# EXECUTABLES
###############################################################################
executable("snapshotter_integration_test_exe") {
testonly = true
sources = [ "snapshotter_integration_test.cc" ]
deps = [
"//sdk/fidl/fuchsia.mem",
"//src/developer/forensics/snapshot:snapshotter",
"//src/developer/forensics/utils:archive",
"//src/lib/files",
"//src/lib/fsl",
"//src/lib/fxl/test:gtest_main",
"//third_party/googletest:gtest",
]
}
executable("snapshotter_unittest_exe") {
testonly = true
sources = [ "snapshotter_unittest.cc" ]
deps = [
"//sdk/fidl/fuchsia.feedback",
"//sdk/lib/sys/cpp/testing:unit",
"//sdk/lib/syslog/cpp",
"//src/developer/forensics/snapshot:snapshotter",
"//src/developer/forensics/testing/stubs:data_provider",
"//src/lib/files",
"//src/lib/fsl",
"//src/lib/fxl/test:gtest_main",
"//src/lib/testing/loop_fixture",
"//third_party/googletest:gtest",
"//zircon/public/lib/zx",
"//zircon/system/ulib/async-loop:async-loop-cpp",
"//zircon/system/ulib/async-loop:async-loop-default",
]
}
###############################################################################
# COMPONENTS
###############################################################################
fuchsia_component("snapshotter_integration_test") {
testonly = true
manifest = "meta/snapshotter_integration_test.cmx"
deps = [ ":snapshotter_integration_test_exe" ]
}
fuchsia_component("snapshotter_unittest") {
testonly = true
manifest = "meta/snapshotter_unittest.cmx"
deps = [ ":snapshotter_unittest_exe" ]
}
###############################################################################
# PACKAGES
###############################################################################
fuchsia_test_package("snapshot-tests") {
test_components = [
":snapshotter_integration_test",
":snapshotter_unittest",
]
}
###############################################################################
# GROUPS
###############################################################################
group("tests") {
testonly = true
deps = [
":snapshot-tests",
# Packages for the components that we are injecting in the integration tests.
"//src/developer/forensics/testing/fakes:fake-data-provider",
]
}