Files
mtusi2026lab2/student-tests/failures.compose.yml
T
ricoromaandClaude Opus 5.5 5b65051a60 test: add automatic failure checks on a separate stand
make failure_checks brings up a throwaway compose project with its own
PostgreSQL and Valkey, a default and a tight API (2 s sessions, pool of
one), and runs the pytest tests marked fault through an explicit hook:
session expiry, database stop and return, pool exhaustion, chat creation
rollback, readiness, Valkey stop, hang, return and flush. The stand and
its volume are removed on any outcome; the working stand is untouched.
Regular runs deselect the fault tests, and 13 coverage exclusions go away.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 23:20:34 +03:00

13 lines
603 B
YAML

# Override стенда отказов make failure_checks (student-tests/run_failures.py):
# тот же docker-compose.yml под проектом mtusi-lab2-failures, со своим
# volume и сетью. Порты Postgres и Valkey не публикуются: к ним ходит только
# fault_hook.py через docker compose exec. Сервис api не запускается,
# контейнеры API создаёт оркестратор (docker compose run -p 127.0.0.1:...).
services:
postgres:
ports: !reset []
valkey:
ports: !reset []
api:
ports: !reset []