Various cleanups (#101)

* Rename BUILD files to match the rest of the repo.

* Move host tests to a specific subpackage

* Add a gitignore file
This commit is contained in:
John Cater 2024-08-26 13:02:58 -04:00 committed by GitHub
parent d3b78bbcf0
commit d5fcb55bf8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 13 additions and 9 deletions

2
.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
MODULE.bazel.lock
bazel-*

View File

@ -1,11 +1,10 @@
load("//:version.bzl", "version") load("//:version.bzl", "version")
load("//host:constraints.bzl", "HOST_CONSTRAINTS")
package(default_visibility = ["//visibility:private"]) package(default_visibility = ["//visibility:private"])
# This is a quick hack to make sure that version.bzl agrees with MODULE.bazel # This is a quick hack to make sure that version.bzl agrees with MODULE.bazel
# It only works from Linux, but that is sufficient, becuase we do a presubmit # It only works from Linux, but that is sufficient, becuase we do a presubmit
# run linux, so we will still catch a mismatch. # run on linux, so we will still catch a mismatch.
genrule( genrule(
name = "versions_match", name = "versions_match",
outs = ["found_it"], outs = ["found_it"],
@ -20,10 +19,3 @@ genrule(
"//:MODULE.bazel", "//:MODULE.bazel",
], ],
) )
sh_test(
name = "host_constraints_test",
srcs = ["host_constraints_test.sh"],
env = {"ACTUAL_HOST_CONSTRAINTS": repr(HOST_CONSTRAINTS)},
env_inherit = ["EXPECTED_HOST_CONSTRAINTS"],
)

10
tests/host/BUILD Normal file
View File

@ -0,0 +1,10 @@
load("//host:constraints.bzl", "HOST_CONSTRAINTS")
package(default_visibility = ["//visibility:private"])
sh_test(
name = "host_constraints_test",
srcs = ["host_constraints_test.sh"],
env = {"ACTUAL_HOST_CONSTRAINTS": repr(HOST_CONSTRAINTS)},
env_inherit = ["EXPECTED_HOST_CONSTRAINTS"],
)