diff --git a/AGENTS.md b/AGENTS.md index b06a88df9..86ae5af11 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -131,10 +131,9 @@ alembic upgrade head ### Parallel backend tests (verification-gated) - Between merge iterations, run affected selectors or `python -m pytest --lf --last-failed-no-failures=none`; do not launch the full suite as an interim check when the last-failed cache is empty. -- The full parallel command is `python -m pytest -n auto --max-worker-restart=0`, after a targeted `-n 2` worker-isolation proof. Run PostgreSQL-backed xdist tests outside the Codex sandbox. -- Status (2026-10-12): targeted `-n 2` proof passed (JUnit 3/3; live-isolation and batch guards 0, selected-coordinate guard 1; pure guards 5/5). Source operations remained 217→217 and cleanup left no run-owned database or temporary PostgreSQL root. Full backend, Ruff, frontend, and report-size comparison remain pending. -- The controller must provision a fresh owned PostgreSQL database and exact per-worker connection descriptor, plus a worker-specific `STORAGE_ROOT_PATH`. Keep descriptors in private `/tmp` files, never in the repository, Git-ignored artifacts, or command-line arguments; cleanup only databases created by that run. -- Keep pytest warning capture enabled and write only `junit.xml` for the parallel test report; do not write reportlog. Check the actual process exit and normal pytest run summary. The historical 347 accounting/list and test replacements remain unchanged and are not an xdist merge condition. +- After the targeted `-n 2` worker-isolation proof, run the full backend suite from `backend/` with `python -m pytest -n auto --max-worker-restart=0 --run-isolated-pg-workers`. Run PostgreSQL-backed xdist tests outside the Codex sandbox. +- Before the command, activate `backend/.venv` and provide a reachable `DATABASE_URL` plus a mode-restricted `PG_CONSUMER_CONNECTION_FILE` descriptor whose database identity and credentials match that URL. The venv must include pytest-xdist and the project test dependencies; the controller creates fresh run-owned PostgreSQL databases, per-worker descriptors, and worker-specific storage roots. +- Keep pytest warning capture enabled and write only `junit.xml`; do not write reportlog. Check the actual process exit, pytest summary, and JUnit result. The historical 347 accounting/list and test replacements remain unchanged and are not an xdist merge condition. - The `serial` marker is currently unused. Mark a test serial only after proving its specific shared resource cannot be isolated, and run that marked subset separately and sequentially. Для спеки 044: