Skip to content

Commit 88ee95a

Browse files
committed
ci: add a job to run tests on forks
1 parent d6a53e6 commit 88ee95a

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/ci.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ jobs:
1616
tests:
1717
name: "Tests"
1818
runs-on: ${{ matrix.os }}
19+
if: ${{ !github.event.pull_request.head.repo.fork }}
1920
strategy:
2021
fail-fast: false
2122
matrix:
@@ -60,6 +61,7 @@ jobs:
6061
test-rsconnect:
6162
name: "Test RSConnect"
6263
runs-on: ubuntu-latest
64+
if: ${{ !github.event.pull_request.head.repo.fork }}
6365
steps:
6466
- uses: actions/checkout@v2
6567
- uses: actions/setup-python@v2
@@ -83,6 +85,27 @@ jobs:
8385
run: |
8486
pytest pins -m 'fs_rsc and not skip_on_github'
8587
88+
89+
test-fork:
90+
name: "Test a fork PR (no secrets)"
91+
runs-on: ubuntu-latest
92+
if: ${{ github.event.pull_request.head.repo.fork }}
93+
steps:
94+
- uses: actions/checkout@v2
95+
- uses: actions/setup-python@v2
96+
with:
97+
python-version: 3.10
98+
- name: Install dependencies
99+
run: |
100+
python -m pip install --upgrade pip
101+
102+
python -m pip install -e .[test]
103+
- name: Run tests
104+
run: |
105+
# TODO: better way to disable all cloud backend tests?
106+
pytest pins -m 'not fs_rsc and not fs_s3 and not skip_on_github'
107+
108+
86109
check-cross-compatibility:
87110
name: "Check cross lib compatibility"
88111
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)