Skip to content

Commit

Permalink
Only release if tests pasts
Browse files Browse the repository at this point in the history
  • Loading branch information
VirginiaDooley committed Apr 16, 2024
1 parent 3a180b4 commit 30ebf06
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,13 @@ name: Publish Python Package

on:
release:
types: [created, edited]
types: [created]
workflow_run:
workflows: ["Run Tests"]
types:
- completed
branches:
- master

jobs:
test:
Expand All @@ -26,6 +32,7 @@ jobs:
run: |
pytest
deploy:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
needs: [test]
environment: release
Expand Down

0 comments on commit 30ebf06

Please sign in to comment.