forked from mtusi2026/mtusi2026lab2
TypeScript/Node API на PostgreSQL с сессиями в Valkey (AOF), миграции, compose-стенд, restart hook, тесты уровня 4 и эксперимент трека 2 (планы запроса на 240k сообщений, стоимость записи, backup/restore).
8 lines
852 B
Plaintext
8 lines
852 B
Plaintext
PASS test_registration_race - 20 parallel registrations of one username -> 1x201, 19x409, 1 row
|
|
PASS test_chat_rollback - chat with unknown member -> 400, no chat/member rows (transaction rolled back)
|
|
PASS test_pagination_and_injection - 57 messages over limit=7 pages: exact order, no dupes; foreign/garbage cursor -> 400; SQL text stored verbatim
|
|
PASS test_wrong_password_and_logout - wrong password / unknown user -> identical 401 Basic; logout -> 204, then 401 twice
|
|
PASS test_expiry - SESSION_TTL_SECONDS=2: 200 right after login, 401 after 3 s on both API processes
|
|
PASS test_valkey_outage - valkey stopped -> ready/me 503 unavailable in 0.02s, anonymous 401, registration 201; recovered with same token
|
|
PASS test_postgres_outage - postgres stopped -> ready/me 503 unavailable in 2.01s, anonymous 401, registration 503; recovered with same token
|