Skip to content

chore(ci): add codecov.yml to enable project check and PR comment #110

chore(ci): add codecov.yml to enable project check and PR comment

chore(ci): add codecov.yml to enable project check and PR comment #110

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11", "3.12", "3.13", "3.14"]
continue-on-error: ${{ matrix.python-version == '3.14' }}
steps:
- uses: actions/checkout@v6
- uses: astral-sh/setup-uv@v8.1.0
with:
version: "latest"
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install dependencies
run: uv sync --all-extras --dev
- name: Run tests
run: uv run pytest tests/ -v --cov=cubepi --cov-report=term-missing --cov-report=xml
- name: Upload coverage to Codecov
if: matrix.python-version == '3.13'
uses: codecov/codecov-action@v6
with:
files: coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: false
- name: Check import
run: uv run python -c "import cubepi; print(cubepi.__all__)"
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: astral-sh/setup-uv@v8.1.0
with:
version: "latest"
- name: Install dependencies
run: uv sync --all-extras --dev
- name: Ruff check
run: uv run ruff check cubepi/ tests/
- name: Ruff format check
run: uv run ruff format --check cubepi/ tests/