Skip to content

Commit

Permalink
Pass os to the action.
Browse files Browse the repository at this point in the history
  • Loading branch information
cgrindel committed Dec 14, 2023
1 parent b189089 commit 2f542cc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/actions/run_bazel_test/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ description: Handles platform-specific settings.
inputs:
working-directory:
type: string
os:
type: string

runs:
using: composite
env:
BAZEL_SH: ${{ runner.os == 'Windows' && 'C:\msys64\usr\bin\bash.exe' || '' }}
BAZEL_SH: ${{ startswith(inputs.os, 'windows-') && 'C:\msys64\usr\bin\bash.exe' || '' }}
RBT_WORKING_DIR: ${{ inputs.working-directory }}
steps:
- shell: bash
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,13 @@ jobs:
- name: Run Bazel test at root
if: ${{ matrix.bazel_mode == 'workspace' }}
uses: ./.github/actions/run_bazel_test
with:
os: ${{ matrix.os }}
- name: Run Bazel test under tests directory
uses: ./.github/actions/run_bazel_test
with:
working-directory: tests
os: ${{ matrix.os }}

# - name: Run tests (bzlmod)
# if: matrix.bazel_mode == 'module'
Expand Down

0 comments on commit 2f542cc

Please sign in to comment.