-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
merge new check-for-skip job into setup job
Since the check-for-skip work needs pretty much the same setup as the setup job, merge the two and avoid the extra job.
- Loading branch information
Showing
1 changed file
with
7 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,29 +10,11 @@ on: | |
- master | ||
|
||
jobs: | ||
check-for-skip: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
skip_tests: ${{ steps.check_for_skip.outputs.skip_tests }} | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Babashka | ||
uses: DeLaGuardo/[email protected] | ||
with: | ||
bb: 'latest' | ||
|
||
- name: Check if Tests Should Run | ||
id: check_for_skip | ||
run: bb -ci-set-skip-tests | ||
|
||
setup: | ||
needs: check-for-skip | ||
runs-on: ubuntu-latest | ||
if: needs.check-for-skip.outputs.skip_tests == 'false' | ||
|
||
outputs: | ||
skip_tests: ${{ steps.check_for_skip.outputs.skip_tests }} | ||
tests: ${{ steps.set-tests.outputs.tests }} | ||
|
||
steps: | ||
|
@@ -64,14 +46,20 @@ jobs: | |
- name: Bring down deps | ||
run: bb download-deps | ||
|
||
- name: Check if Tests Should Run | ||
id: check_for_skip | ||
run: bb -ci-set-skip-tests | ||
|
||
- id: set-tests | ||
if: steps.check_for_skip.skip_tests = 'false' | ||
name: Set test var for matrix | ||
# run test.clj directly instead of via bb task to avoid generic task output | ||
run: echo "tests=$(bb script/test_matrix.clj --format json)" >> $GITHUB_OUTPUT | ||
|
||
build: | ||
needs: setup | ||
runs-on: ${{ matrix.os }}-latest | ||
if: needs.setup.outputs.skip_tests == 'false' | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
|