Skip to content

Commit

Permalink
Add input to enable testing
Browse files Browse the repository at this point in the history
  • Loading branch information
raydouglass committed Aug 2, 2023
1 parent e473c24 commit ef93b1a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/build-test-publish-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ on:
build_type:
required: true
type: string
run_tests:
required: false
default: false
type: boolean

defaults:
run:
Expand Down Expand Up @@ -123,8 +127,7 @@ jobs:
py${{ matrix.PYTHON_VER }}"
test:
needs: [build, compute-matrix]
# TODO: nightly tests
if: inputs.build_type == 'pull-request'
if: inputs.run_tests
strategy:
matrix: ${{ fromJSON(needs.compute-matrix.outputs.TEST_MATRIX) }}
fail-fast: false
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ jobs:
uses: ./.github/workflows/build-test-publish-images.yml
with:
build_type: pull-request
run_tests: true
secrets: inherit
6 changes: 6 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ on:
tags:
- v[0-9][0-9].[0-9][0-9].[0-9][0-9]
workflow_dispatch:
inputs:
run_tests:
required: false
default: false
type: boolean

concurrency:
group: "${{ github.workflow }} @ ${{ github.ref }}"
Expand All @@ -17,6 +22,7 @@ jobs:
uses: ./.github/workflows/build-test-publish-images.yml
with:
build_type: branch
run_tests: ${{ inputs.run_tests || false }}
secrets: inherit
readme:
runs-on: ubuntu-latest
Expand Down

0 comments on commit ef93b1a

Please sign in to comment.