From 9a933772e87dfcf684590eb74eee9970e8b66669 Mon Sep 17 00:00:00 2001 From: Laszlo Csomor Date: Tue, 14 Aug 2018 08:29:29 -0700 Subject: test-wrapper: add empty impl + Bazel flag This commit adds: - the skeleton implementation of the Windows native test wrapper - a depenency on the native test wrapper from test rules, through the new $test_wrapper rule attribute - the --windows_native_test_wrapper Bazel flag, which is currently a no-op See https://github.com/bazelbuild/bazel/issues/5508 Change-Id: I8df95c8ce8bab53c51c257698ec95416065a836e Closes #5854. Change-Id: I2ffc78bceec5dd867af775b5878f105fa87c3dba PiperOrigin-RevId: 208650699 --- tools/test/BUILD | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'tools/test/BUILD') diff --git a/tools/test/BUILD b/tools/test/BUILD index 18dc71b493..4d5a3ab212 100644 --- a/tools/test/BUILD +++ b/tools/test/BUILD @@ -33,6 +33,15 @@ filegroup( srcs = ["@bazel_tools//tools/test/LcovMerger/java/com/google/devtools/lcovmerger:Main"], ) +cc_binary( + name = "test_wrapper_bin", + srcs = select({ + "@bazel_tools//src/conditions:windows": ["windows/test_wrapper.cc"], + "//conditions:default": ["empty_test_wrapper.cc"], + }), + visibility = ["//visibility:private"], +) + filegroup( name = "srcs", srcs = glob(["**"]), @@ -45,7 +54,10 @@ filegroup( "test-setup.sh", "generate-xml.sh", "collect_coverage.sh", - ] + glob(["LcovMerger/**"]), + ] + glob(["LcovMerger/**"]) + select({ + "@bazel_tools//src/conditions:windows": ["test_wrapper_bin"], + "//conditions:default": [], + }), visibility = ["//tools:__pkg__"], ) -- cgit v1.2.3