Skip to content

Commit

Permalink
GHA: Fix actions for PRs from forks
Browse files Browse the repository at this point in the history
* run codecov only on pull requests
* trigger relevant actions on `pull_request` instead of only on `push`

Closes #2218
  • Loading branch information
dweindl committed Dec 1, 2023
1 parent b0eedd9 commit 70114b3
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/test_install.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Installation
on: [push, merge_group, workflow_dispatch]
on: [push, pull_request, merge_group, workflow_dispatch]

jobs:
archive:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test_petab_test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ jobs:
tests/petab_test_suite/
- name: Codecov
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/test_python_cplusplus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ on:
pull_request:
branches:
- master
- develop

jobs:
ubuntu-cpp-python-tests:
Expand Down Expand Up @@ -65,6 +66,7 @@ jobs:
${AMICI_DIR}/python/tests/test_splines.py
- name: Codecov Python
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand All @@ -84,6 +86,7 @@ jobs:
&& lcov -a coverage_cpp.info -a coverage_py.info -o coverage.info
- name: Codecov CPP
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand Down Expand Up @@ -137,6 +140,7 @@ jobs:
${AMICI_DIR}/python/tests/test_splines_short.py
- name: Codecov Python
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand All @@ -156,6 +160,7 @@ jobs:
&& lcov -a coverage_cpp.info -a coverage_py.info -o coverage.info
- name: Codecov CPP
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test_sbml_semantic_test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ jobs:
path: tests/amici-semantic-results

- name: Codecov SBMLSuite
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
- cron: '48 4 * * *'
pull_request:
branches:
- develop
- master

jobs:
Expand Down

0 comments on commit 70114b3

Please sign in to comment.