Skip to content

Commit

Permalink
Add missing lockfile and checks. (#200)
Browse files Browse the repository at this point in the history
This was missed as part of upgrading to Bazel 7 in #198
  • Loading branch information
SanjayVas authored Feb 13, 2024
1 parent 7bd3df0 commit 87d85e8
Show file tree
Hide file tree
Showing 3 changed files with 1,861 additions and 5 deletions.
4 changes: 4 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
common --enable_bzlmod
common --registry=https://raw.githubusercontent.com/world-federation-of-advertisers/bazel-registry/main
common --registry=https://bcr.bazel.build

# Configuration for continuous integration (CI).
common:ci --lockfile_mode=error
build:ci --compilation_mode=opt
28 changes: 23 additions & 5 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,27 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: Check out revision
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Bazel build and test
uses: world-federation-of-advertisers/actions/bazel-build-test@v1
with:
workspace-path: .
- name: Write ~/.bazelrc
run: |
echo 'common --config=ci' >> ~/.bazelrc
- name: Set up Bazel
run: |
mkdir -p ~/.local/bin
bazelisk_path="$(which bazelisk)"
ln -s "${bazelisk_path}" ~/.local/bin/bazel
- name: Build
run: |
bazel build //...
- name: Test
id: run-tests
run: |
bazel test //... || (( $? == 4 ))
- name: Upload Bazel testlogs
if: failure() && steps.run-tests.outcome == 'failure'
uses: world-federation-of-advertisers/actions/bazel-upload-testlogs@v2
Loading

0 comments on commit 87d85e8

Please sign in to comment.