blob: 7f97b273055c4e0b31727a53dd6e18ce93e1641b [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/bind/bind.gni")
import("//build/drivers.gni")
import("//build/fidl/fidl.gni")
driver_bind_rules("mock-device-bind") {
rules = "mock-device.bind"
deps = [ "//src/devices/bind/fuchsia.test" ]
}
fuchsia_driver("mock-device-driver") {
output_name = "mock-device"
testonly = true
sources = [
"device.cc",
"fidl.cc",
]
deps = [
":fuchsia.device.mock_cpp",
":fuchsia.device.mock_hlcpp",
":mock-device-bind",
"//sdk/banjo/fuchsia.hardware.test:fuchsia.hardware.test_banjo_cpp",
"//sdk/lib/fidl",
"//sdk/lib/fidl/cpp:cpp_base",
"//src/devices/lib/driver",
"//src/lib/ddk",
"//src/lib/ddktl",
"//zircon/system/ulib/fbl",
"//zircon/system/ulib/zircon-internal",
"//zircon/system/ulib/zx",
]
}
fuchsia_driver_component("mock-device") {
testonly = true
component_name = "mock-device"
deps = [ ":mock-device-driver" ]
info = "mock-device-info.json"
manifest = "meta/mock-device.cml"
}
fidl("fuchsia.device.mock") {
testonly = true
sources = [ "mock-device.test.fidl" ]
public_deps = [ "//zircon/vdso/zx" ]
excluded_checks = [ "event-names-must-start-with-on" ]
enable_hlcpp = true
}