-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (48 loc) · 1.46 KB
/
ci.yaml
File metadata and controls
53 lines (48 loc) · 1.46 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:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
PYTHONUNBUFFERED: "1"
FORCE_COLOR: "1"
jobs:
run:
name: Python ${{ matrix.python-version }}
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.12", "3.13", "3.14"]
steps:
- uses: actions/checkout@v6
- name: Install uv and set up Python ${{ matrix.python-version }}
uses: astral-sh/setup-uv@v7
with:
python-version: ${{ matrix.python-version }}
activate-environment: true
- name: Install the project
run: uv sync
- name: Run prek hooks
run: uv run prek run --all-files
- name: Upload local coverage (lcov.info) if present
if: hashFiles('lcov.info') != ''
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: lcov.info
flags: local
fail_ci_if_error: false
- name: Run tests
run: uv run pytest --cov-report=lcov:github-lcov.info
- name: Upload CI coverage (github-lcov.info) if present
if: success() && hashFiles('github-lcov.info') != ''
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: github-lcov.info
flags: ci
fail_ci_if_error: false