Skip to content

change to uv

change to uv #30

# This workflow will install Python dependencies, run tests and lint with a
# variety of Python versions
#
# In addition, code coverage is reported to Coveralls
#
# For more information see:
# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
name: Python package
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- name: Install uv
uses: astral-sh/setup-uv@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
python-version-file: ".python-version"
- name: Install the project
run: uv sync --all-extras --dev
# - name: Check code
# run: |
# make check
- name: Run tests and check coverage
run: |
uv run coverage run -m pytest
uv run coverage lcov
- name: Code Coverage
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: coverage.lcov