Skip to content

Commit 2f79af7

Browse files
committed
move integrations to separate workflow (#48)
1 parent 82b23fa commit 2f79af7

File tree

2 files changed

+45
-9
lines changed

2 files changed

+45
-9
lines changed

.github/workflows/ci-cloud.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Cloud integration
2+
3+
# see: https://help.github.com/en/actions/reference/events-that-trigger-workflows
4+
on: [push, workflow_dispatch]
5+
6+
defaults:
7+
run:
8+
shell: bash
9+
10+
jobs:
11+
pytester:
12+
runs-on: ${{ matrix.os }}
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
os: ["ubuntu-22.04", "macOS-13", "windows-2022"]
17+
python-version: ["3.10"]
18+
19+
# Timeout: https://stackoverflow.com/a/59076067/4521646
20+
timeout-minutes: 35
21+
env:
22+
TORCH_URL: "https://download.pytorch.org/whl/cpu/torch_stable.html"
23+
24+
steps:
25+
- uses: actions/checkout@v4
26+
- name: Set up Python ${{ matrix.python-version }}
27+
uses: actions/setup-python@v5
28+
with:
29+
python-version: ${{ matrix.python-version }}
30+
cache: "pip"
31+
32+
- name: Install package & dependencies
33+
run: |
34+
pip --version
35+
pip install -e '.[test,extra]' -U -q --find-links $TORCH_URL
36+
pip list
37+
38+
- name: Test integrations
39+
env:
40+
LIGHTNING_USER_ID: ${{ secrets.LIGHTNING_USER_ID }}
41+
LIGHTNING_API_KEY: ${{ secrets.LIGHTNING_API_KEY }}
42+
run: |
43+
coverage run --source litmodels -m pytest src tests -v -m cloud
44+
timeout-minutes: 5

.github/workflows/ci-testing.yml

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: CI testing
33
# see: https://help.github.com/en/actions/reference/events-that-trigger-workflows
44
on: # Trigger the workflow on push or pull request, but only for the main branch
55
push: {}
6-
pull_request_target:
6+
pull_request:
77
branches: [main]
88

99
defaults:
@@ -51,14 +51,6 @@ jobs:
5151
run: |
5252
coverage run --source litmodels -m pytest src tests -v -m "not cloud"
5353
54-
- name: Test integrations
55-
env:
56-
LIGHTNING_USER_ID: ${{ secrets.LIGHTNING_USER_ID }}
57-
LIGHTNING_API_KEY: ${{ secrets.LIGHTNING_API_KEY }}
58-
run: |
59-
coverage run --source litmodels -m pytest src tests -v -m cloud
60-
timeout-minutes: 5
61-
6254
- name: Statistics
6355
run: |
6456
coverage report

0 commit comments

Comments
 (0)