Move tests to pytest and add a CI job #25

Closed
opened 2026-08-17 16:57:01 -04:00 by mysticalsoap · 0 comments
Owner

The five scripts in tests/ already follow the shape pytest formalises
-- test_ovpn_quote.py even skips when OpenVPN is absent. Converting
print/manual-assert to assert + pytest.mark.skipif is mechanical and buys
collection, selection, fixtures and a real exit code.

Keep tests/manual/bypass_cgroup.py out of the default run; it needs root.

Add a CI job running pytest on push. None of the current tests need root,
network or a VPN account, so it runs anywhere. Include a lint step
(ruff/pyflakes, or -W error::SyntaxWarning) -- that alone would have caught
both the escape-sequence warnings and the conf.ROOTDIR typo before they
shipped.

The five scripts in `tests/` already follow the shape pytest formalises -- `test_ovpn_quote.py` even skips when OpenVPN is absent. Converting `print`/manual-assert to `assert` + `pytest.mark.skipif` is mechanical and buys collection, selection, fixtures and a real exit code. Keep `tests/manual/bypass_cgroup.py` out of the default run; it needs root. Add a CI job running `pytest` on push. None of the current tests need root, network or a VPN account, so it runs anywhere. Include a lint step (`ruff`/`pyflakes`, or `-W error::SyntaxWarning`) -- that alone would have caught both the escape-sequence warnings and the `conf.ROOTDIR` typo before they shipped.
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
mysticalsoap/aqomui#25
No description provided.