Run Tests and Type Checks

All tests

uv run --extra dev pytest

The suite splits into:

  • tests/test_cli.py — end-to-end anchor test against the 9 interview fixtures, plus --version smoke.
  • tests/test_match.py — combiner unit tests (weights, threshold, boundary cases).
  • tests/test_score.py — per-field scorers, parametrized across every fixture shape.
  • tests/test_nicknames.py — equivalence-class loading, transitive merging, and the real-file invariant that cycyril.

Just the scorers

uv run --extra dev pytest tests/test_score.py -v

The anchor test

uv run --extra dev pytest tests/test_cli.py::test_anchor_full_output -v

This is the project’s spec test. Its expected output is hard-coded to the 9-link ground-truth verdicts in interview/plan.md. If you change any scorer, threshold, or weight, run this to confirm you haven’t regressed the fixtures.

Type checking

uv run ty check src tests

Ty (Astral’s Rust-based type checker) is wired into prek as a gating hook, so it also runs automatically on every commit.

Everything prek runs

prek run --all-files

Covers ruff, ruff-format, ty, pytest, the changelog-fragment check, and the various docs validators.

Running the CLI during development

See run-matcher.