Skip to content

Replace old testing suite with ty and ruff #3

Replace old testing suite with ty and ruff

Replace old testing suite with ty and ruff #3

Workflow file for this run

name: CI Checks
on: [push]
jobs:
autoformat:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install the project
run: uv sync --frozen --extra develop
- name: Run Ruff format (check)
run: uv run --no-sync ruff format --check .
linting:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install the project
run: uv sync --frozen --extra develop
- name: Ruff check
run: uv run --no-sync ruff check .
static-type-checking:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install the project
run: uv sync --frozen --extra develop
- name: ty check
run: uv run --no-sync ty check
unit-tests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- name: Install LAPACK and BLAS
run: |
sudo apt-get update
sudo apt-get install -y liblapack-dev libblas-dev
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}
- name: Install the project
run: uv sync --frozen --extra develop
- name: Pytest
run: |
uv run --no-sync pytest tests/