Add the CI workflow and make it run on this project #21

Merged
Tirsvad merged 1 commits from fix-ci-workflow into main 2026-10-07 19:22:33 +02:00
1 Commits
Author SHA1 Message Date
Tirsvad fed7e17527 Add the CI workflow and make it run on this project
CI / checks (push) Successful in 1m17s
CI / checks (pull_request) Successful in 1m18s
Add .gitea/workflows/ci.yml: tests, ruff check, ruff format --check and mypy on
every push and pull request, with Python 3.13 on ubuntu-latest.

Two things in the first draft would have failed:

- It installed the dev tools with `pip install -e ".[dev]"`, but the project
  declares them as a dependency group, not an extra. pip only warns and exits 0,
  so pytest, ruff and mypy were missing and the first step died with "No module
  named pytest". It now runs `pip install -e . --group dev`.
- The 10 test cases that use Tk need a display, which a CI runner does not have.
  The workflow now installs xvfb and python3-tk and runs the tests with
  xvfb-run, so the display requirement accepted on RC-006 still holds. No test
  code changes.

Checked locally: the YAML parses to the intended eight steps, the install line
gives all three tools in a clean environment, and the test, lint, format and
type commands pass as written. The Linux display steps have not run yet; they
need a runner.
2026-10-08 01:18:47 +08:00