| # 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/bind/bind.gni") |
| import("//build/config/fuchsia/rules.gni") |
| import("//build/test.gni") |
| import("//zircon/system/ulib/devmgr-integration-test/isolated_devmgr.gni") |
| |
| bind_rules("metadata-test-bind") { |
| rules = "metadata-test.bind" |
| output = "metadata-test-bind.h" |
| deps = [ "//src/devices/bind/test.platform" ] |
| } |
| |
| driver_module("isolateddevmgr-test-driver") { |
| sources = [ "test-driver.cc" ] |
| deps = [ |
| ":metadata-test-bind", |
| "//sdk/fidl/fuchsia.device.manager.test:fuchsia.device.manager.test_c", |
| "//sdk/lib/fdio", |
| "//src/devices/lib/driver", |
| "//src/lib/ddk", |
| "//src/lib/ddktl", |
| ] |
| } |
| |
| test("isolateddevmgr") { |
| output_name = "isolateddevmgr-test" |
| configs += [ "//build/unification/config:zircon-migrated" ] |
| sources = [ "test.cc" ] |
| deps = [ |
| "//sdk/fidl/fuchsia.device.manager.test:fuchsia.device.manager.test_c", |
| "//sdk/lib/fdio", |
| "//src/lib/ddk", |
| |
| # TODO(fxb/38132): Migrate to the new bind rules and delete the below |
| "//src/lib/ddk:ddk-deprecated-binding-headers", |
| "//zircon/public/lib/fbl", |
| "//zircon/public/lib/zx", |
| "//zircon/public/lib/zxtest", |
| "//zircon/system/ulib/devmgr-integration-test", |
| "//zircon/system/ulib/devmgr-launcher", |
| "//zircon/system/ulib/driver-integration-test", |
| ] |
| } |
| |
| isolated_devmgr_unittest_package("isolateddevmgr-test") { |
| package_name = "isolateddevmgr" |
| executable_path = "test/isolateddevmgr-test" |
| |
| deps = [ |
| ":isolateddevmgr", |
| ":isolateddevmgr-test-driver", |
| "//src/devices/board/drivers/integration-test", |
| "//src/devices/bus/drivers/platform", |
| ] |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":isolateddevmgr-test" ] |
| } |