Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 2 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ on:

jobs:
build:

runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand All @@ -16,13 +15,7 @@ jobs:
- macos-latest
- ubuntu-latest
- windows-latest

steps:
- uses: actions/checkout@v6
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox
- name: Test
run: |
tox
- uses: jdx/mise-action@v3
- run: ./build_and_test
23 changes: 23 additions & 0 deletions .mise.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
[tools]
uv = "latest"

[env.'_'.python.venv]
path = ".venv"
create = true
uv_create_args = ["--seed", "--quiet"]

[tasks]
"pip-install" = "uv pip --no-cache install -r requirements.txt --quiet"
build_and_test.depends = ["check_formatting", "test", "mypy"]

[tasks.check_formatting]
run = "python -m black --check ."
depends = ["pip-install"]

[tasks.test]
run = "python -m pytest -v"
depends = ["pip-install"]

[tasks.mypy]
run = "python -m mypy ."
depends = ["pip-install"]
11 changes: 8 additions & 3 deletions build_and_test
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
#! /bin/sh -eu
#! /usr/bin/env bash
set -euo pipefail

python3 -m pip install tox --disable-pip-version-check
python3 -m tox --parallel
if ! command -v mise >/dev/null 2>&1; then
echo "[error] 'mise' is required but not found on PATH. Install Mise: https://mise.jdx.dev/"
exit 127
fi

mise task --quiet run build_and_test
2 changes: 1 addition & 1 deletion build_and_test.cmd
Original file line number Diff line number Diff line change
@@ -1 +1 @@
@call python -m pip install tox --disable-pip-version-check && call tox --parallel
@"C:\Program Files\Git\bin\bash.exe" ./build_and_test
26 changes: 0 additions & 26 deletions tox.ini

This file was deleted.