-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (43 loc) · 1.15 KB
/
ci.yaml
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
name: Lint, format and tests
on:
push:
branches:
- 'main'
pull_request:
jobs:
ruff-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v3
with:
python-version: "3.12"
- run: pip install ruff==0.9.*
- run: ruff check src/
ruff-format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v3
with:
python-version: "3.12"
- run: pip install ruff==0.9.*
- run: ruff format --check src/
test:
needs: [ruff-check, ruff-format]
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- run: pip install pytest
- run: pip install .
- name: Run tests
# Run two example test modules
# Most tests in the tests/ directory date back to vortex 1.* and need
# to be ported to vortex 2.*. This is ongoing work.
run: python -m pytest tests/test_config.py tests/tests_algo/test_basics.py