Skip to content

Bump version: 0.5.8 → 0.6.0 #120

Bump version: 0.5.8 → 0.6.0

Bump version: 0.5.8 → 0.6.0 #120

name: Python package
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
lint:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.12']
steps:
- name: Check out the code
uses: actions/checkout@v3
- name: Set up uv
uses: hynek/setup-cached-uv@v2
with:
cache-dependency-path: uv.lock
- name: Pin Python version
run: uv python pin ${{ matrix.python-version }}
- name: Lint check
run: uvx ruff check
- name: Check formatting
run: uvx ruff format --check
test:
runs-on: ubuntu-latest
strategy:
matrix:
settings:
- python: '3.9'
coverage: false
- python: '3.10'
coverage: false
- python: '3.11'
coverage: false
- python: '3.12'
coverage: true
steps:
- name: Check out the code
uses: actions/checkout@v3
- name: Set up uv
uses: hynek/setup-cached-uv@v2
with:
cache-dependency-path: uv.lock
- name: Pin Python version
run: uv python pin ${{ matrix.settings.python }}
- name: Sync dependencies
run: uv sync --all-extras
- name: Test with pytest
if: ${{ !matrix.settings.coverage }}
run: uv run pytest tests/
- name: Test with pytest and coverage
if: ${{ matrix.settings.coverage }}
run: uv run pytest --cov=src --cov-report term-missing tests/
- name: Verify coverage
if: ${{ matrix.settings.coverage }}
run: uv run coverage report | tail -1 | egrep "TOTAL +[0-9]+ +0 +100%"