Skip to content

Commit

Permalink
Allow tox workflow to receive an optional environment argument (#238)
Browse files Browse the repository at this point in the history
  • Loading branch information
ssbarnea authored Oct 21, 2024
1 parent 63b2571 commit e74851c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@ on:
description: Default python version for other jobs
required: false
type: string
environment:
default: ""
description: Which GHA environment to use
required: false
type: string
jobs_producing_coverage:
default: 6
description: Number of jobs producing coverage.xml files
Expand Down Expand Up @@ -58,6 +63,7 @@ jobs:
prepare:
name: prepare
runs-on: ubuntu-24.04
environment: ${{ inputs.environment }}
outputs:
matrix: ${{ steps.generate_matrix.outputs.matrix }}
steps:
Expand All @@ -76,6 +82,7 @@ jobs:
test:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os || 'ubuntu-24.04' }}
environment: ${{ inputs.environment }}
needs:
- prepare
defaults:
Expand Down Expand Up @@ -158,6 +165,7 @@ jobs:
# https://github.com/actions/toolkit/issues/193
check:
if: always()
environment: ${{ inputs.environment }}
permissions:
pull-requests: write # allow codenotify to comment on pull-request
id-token: write
Expand Down

0 comments on commit e74851c

Please sign in to comment.