Unit Tests #269
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Tests for all supported versions [Python 3.9|3.10|3.11|3.12] | |
name: Unit Tests | |
on: | |
schedule: | |
- cron: '0 1 * * 1' | |
workflow_dispatch: | |
push: | |
branches: [ main, v1_feature_branch ] | |
paths-ignore: | |
pyproject.toml | |
env: | |
UV_SYSTEM_PYTHON: true | |
jobs: | |
pytest: | |
runs-on: ubuntu-latest | |
# Using matrix strategy | |
strategy: | |
matrix: | |
python-version: ["3.9", "3.10", "3.11", "3.12"] | |
steps: | |
# Check out repo and set up Python | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
curl -LsSf https://astral.sh/uv/install.sh | sh | |
- name: Install package | |
run: | | |
uv pip install ".[dev]" | |
- name: Run tests on python ${{matrix.python-version}} | |
run: | | |
pytest --full-trace --show-capture=no -sv -n auto tests/ |