fork/rules_rust

git clone https://git.julia.blue/fork/rules_rust

UebelAndreAvoid uses of shell to improve Windows tests (#2912)16cd457b

cleanup
721 B20 linesraw
1load("@bazel_skylib//rules:build_test.bzl", "build_test")
2load(":toolchain_test.bzl", "toolchain_test_suite")
3
4toolchain_test_suite(name = "toolchain_test_suite")
5
6genrule(
7    name = "inspect",
8    outs = ["rustc-cfg"],
9    # rustc assumes it can read things like librustc_driver in order to run this command.
10    # This is a test to ensure we supply all of the files rustc needs as part of the current_rust_toolchain.
11    cmd = "$(RUSTC) --print=cfg > $@",
12    cmd_bat = "$(RUSTC) --print=cfg > $@",
13    toolchains = ["@rules_rust//rust/toolchain:current_rust_toolchain"],
14    tools = ["@rules_rust//rust/toolchain:current_rust_toolchain"],
15)
16
17build_test(
18    name = "inspect_build_test",
19    targets = [":inspect"],
20)