Skip to content

Feature/matrix

Feature/matrix #16

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
name: Python Tests
on:
push:
branches-ignore: [ "main" ]
pull_request:
branches: [ "**" ]
permissions:
contents: write
checks: write
pull-requests: write
jobs:
run-tests:
runs-on: ubuntu-latest
strategy:
matrix:
# Adjust the matrix to test against different or multiple versions.
# Note that adding more versions will result in a code coverage report
# for each version; you may wish to adjust that step's behavior.
python-version: ["3.13"]
steps:
- uses: actions/checkout@09d2acae674a48949e3602304ab46fd20ae0c42f
- name: Set up Python ${{ matrix.python-version }}
uses: astral-sh/setup-uv@252c9954247a3257f40af94d0d836d0ffb58f808
with:
python-version: ${{ matrix.python-version }}
- name: Ruff check
run: |
uvx ruff check
- name: Install dependencies
run: |
uv sync
- name: Test with pytest
run: |
uv run pytest
- name: Report coverage
uses: MishaKav/pytest-coverage-comment@13d3c18e21895566c746187c9ea74736372e5e91
with:
pytest-xml-coverage-path: ./htmlcov/coverage.xml
title: Coverage report for Python ${{ matrix.python-version }}
remove-link-from-badge: true
unique-id-for-comment: ${{ matrix.python-version }}
coverage-path-prefix: src/