-
-
Notifications
You must be signed in to change notification settings - Fork 361
41 lines (32 loc) · 919 Bytes
/
python-test.yaml
File metadata and controls
41 lines (32 loc) · 919 Bytes
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
name: Python Test
on:
push:
branches: [main]
pull_request:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v5
- name: Install uv and set the python version with caching
uses: astral-sh/setup-uv@v6
with:
python-version: ${{ matrix.python-version }}
enable-cache: true
- name: Install the project
run: uv sync --all-extras --dev
- name: Test with pytest
run: uv run py.test
- name: Check lints with ruff
run: uv run ruff check --diff
- name: Check formatting with ruff
run: uv run ruff format --check --diff
- name: Check types with pyright
run: uv run pyright