firegex/tests/pyproject.toml
av0idd4rk 863422f202 Add authenticated MCP server and agent guide
Expose 28 tools with shared REST operations, role-scoped bearer authentication, revisions, durable retries, snapshots, jobs and timed rollback. Add Docker verification harnesses and setup/workflow documentation in docs/mcp.md and inst.md. Validated with 330 unit tests, two consecutive 25-case MCP/import runs, and restart recovery; the full upstream regression run remains incomplete.
2026-10-23 09:46:44 +03:00

57 lines
3.0 KiB
TOML

# Not a package: dependency groups only (PEP 735). `run_tests.sh` installs `test`;
# `bench` is what the benchmarks need on top of it.
[dependency-groups]
test = [
"mcp==2.3.0",
"pytest",
"requests",
"cryptography",
"psutil",
"pydantic",
"python-socketio[client]",
# The only way to speak QUIC from Python, and the integration tests for that layer have
# to speak it: what they check is the half the engine's own tests cannot reach — the
# rules that steer a QUIC address, the relay bound per address, and a filter attached
# through the API. Everything that needs it skips with a reason when it is absent, so a
# machine without it still runs the rest.
"aioquic",
# And the only way to speak gRPC from Python, which is what says HTTP/2 is filtered: a
# gRPC service is a real HTTP/2 service, its method name is an HPACK-compressed `:path`,
# and its status is a trailer section — the three things a firegex that only forwarded
# HTTP/2 could not show a filter. Everything that needs it skips with a reason when it is
# absent, so a machine without it still runs the rest.
"grpcio",
# `unit/test_nftables_addresses.py` imports the **backend** — the address-to-nftables
# translation is the backend's, and testing a copy of it would be testing a copy. That
# drags in `backend/utils`, which raises FastAPI's `HTTPException`, so FastAPI has to be
# here even though nothing in this suite serves a request. Without it the file cannot be
# collected, and a collection error is not one test failing: pytest stops the entire run
# before anything has executed. It went unnoticed for as long as it did because a machine
# that has ever run the backend outside the container already has it.
"fastapi",
# `unit/` imports the filter library straight out of `../fgex-lib`, so its runtime
# dependencies have to be here too. Not the published `firegex` itself, which would
# quietly shadow the source tree the suite is meant to be testing.
#
# The HTTP parser is deliberately NOT here. It is a C extension that ships inside
# firegex itself, so it has to be *built*: `run_tests.sh` does that with an editable
# install of `../fgex-lib`. Running `pytest` by hand without it gives
# `ImportError: cannot import name '_llhttp' from 'firegex'`.
"brotli",
"websockets",
# Unconditional here, unlike in the library, which only needs it below 3.14: the
# suite uses it to build the corpus *and* to exercise the fallback backend, so
# without it the cross-backend agreement test silently skips on the one Python
# that matters most.
"zstandard",
]
# The tests' dependencies stay pure python, so a CI run that only tests does not build a
# binding against a C library it will never call. `iperf3` is one: the library has to be
# installed first (`apt-get install iperf3`, `dnf install iperf3`).
bench = [
{ include-group = "test" },
"iperf3",
"matplotlib",
"numpy",
]