-
Notifications
You must be signed in to change notification settings - Fork 3
86 lines (68 loc) · 2.07 KB
/
Copy pathpython.yaml
File metadata and controls
86 lines (68 loc) · 2.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: FastAPI backend with SQLite
permissions: {}
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build-and-test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.12'
- uses: astral-sh/setup-uv@v5
- name: Install backend
run: uv sync --package acidwatch-api
- name: Run ruff
run: |
uv run --package acidwatch-api ruff format --check src tests packages ../workers
uv run --package acidwatch-api ruff check src tests packages ../workers
- name: Run mypy
run: uv run --package acidwatch-api mypy --strict src packages/acidwatch-models/src packages/acidwatch-messaging/src packages/acidwatch-messaging/typecheck packages/acidwatch-worker-runtime/src
- name: Run pytest
run: |
cp .env.example .env
uv run --package acidwatch-api pytest tests
worker-packages:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- worker: example
test_path: tests
- worker: tocomo
test_path: tests
- worker: arcs
test_path: ""
- worker: arcs-exp
test_path: tests
- worker: solubilityccs
test_path: ""
- worker: gibbs-minimization
test_path: tests
- worker: phpitz-reactive
test_path: ""
- worker: phpitz-solubility
test_path: ""
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.12'
- uses: astral-sh/setup-uv@v5
- name: Install worker
working-directory: workers/${{ matrix.worker }}
run: uv sync
- name: Build worker package
working-directory: workers/${{ matrix.worker }}
run: uv build
- name: Test worker
if: matrix.test_path != ''
working-directory: workers/${{ matrix.worker }}
run: uv run pytest ${{ matrix.test_path }}