Skip to content

Commit

Permalink
[ci] Remove default local = True flag from fpga_params
Browse files Browse the repository at this point in the history
As per https://bazel.build/reference/be/general#genrule.local, Bazel
normally runs tests with a default of `local = False`. Setting `local =
True` as we do by default forces genrule to use the "local" spawn
strategy, which disallows remote execution, sandboxing and remote
caching.

We do not use remote execution, but there is no reason for our FPGA
tests to be run without sandboxing or without using remotely cached
test results (as opposed to locally cached test results). Bazel will
still respect the `cache_test_results` option, and so use of this cache
can be overriden. Any tests that need to use opt out of sandboxing
features as this originally provided can simply add the `local` tag
instead of using this parameter, though this will mean that these tests
cannot be remotely cached and thus must be re-run every time if no
result is cached locally.

Signed-off-by: Alex Jones <[email protected]>
  • Loading branch information
AlexJones0 committed Jan 10, 2025
1 parent 8428ef0 commit d635e8e
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions rules/opentitan/fpga.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,6 @@ fpga_cw340 = rule(
def fpga_params(
tags = [],
timeout = "short",
local = True,
test_harness = None,
binaries = {},
rom = None,
Expand All @@ -236,7 +235,6 @@ def fpga_params(
Args:
tags: The test tags to apply to the test rule.
timeout: The timeout to apply to the test rule.
local: Whether to set the `local` flag on this test.
test_harness: Use an alternative test harness for this test.
binaries: Dict of binary labels to substitution parameter names.
rom: Use an alternate ROM for this test.
Expand Down Expand Up @@ -266,7 +264,7 @@ def fpga_params(
# via the "_hacky_tags" macro in "rules/opentitan/defs.bzl".
tags = ["exclusive"] + (["changes_otp"] if changes_otp else []) + tags,
timeout = timeout,
local = local,
local = False,
test_harness = test_harness,
binaries = binaries,
rom = rom,
Expand Down

0 comments on commit d635e8e

Please sign in to comment.