| # Copyright 2020 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/fidl/toolchain.gni") |
| import("//build/testing/golden_test.gni") |
| import("//zircon/tools/fidl/testdata/info.gni") |
| |
| golden_test("fidlc_golden_tests") { |
| goldens_dir = "goldens" |
| deps = [] |
| entries = [] |
| foreach(info, fidl_testdata_info) { |
| deps += [ "${info.target}($fidl_toolchain)" ] |
| entries += [ |
| { |
| golden = "${info.name}.json.golden" |
| generated = "${info.fidl_gen_dir}/${info.target_name}.fidl.json" |
| }, |
| { |
| golden = "${info.name}.tables.c.golden" |
| generated = "${info.fidl_gen_dir}/${info.target_name}.fidl.tables.c" |
| }, |
| ] |
| } |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":fidlc_golden_tests($host_toolchain)" ] |
| } |