forked from childmindresearch/bids2table
-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (49 loc) · 1.24 KB
/
ci.yaml
File metadata and controls
53 lines (49 loc) · 1.24 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
name: CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
env:
UV_FROZEN: true
jobs:
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: "true"
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
pyproject-file: pyproject.toml
- name: Install the project
run: uv sync --all-extras
- name: Check quality
run: |
uv run ruff check bids2table tests
uv run ruff format --check bids2table tests
tests:
runs-on: ubuntu-latest
needs: format
strategy:
matrix:
python-version: ["3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4
with:
submodules: "true"
- name: Install uv with python version
uses: astral-sh/setup-uv@v6
with:
python-version: ${{ matrix.python-version }}
- name: Run tests
run: |
uv run --all-extras pytest \
--junitxml=pytest.xml \
--cov-report=xml:coverage.xml \
--cov=bids2table tests
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}