forked from mtusi2026/mtusi2026lab2
lab2: PostgreSQL, Flyway migrations, Basic->Bearer sessions, evidence
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
username | hash_prefix
|
||||
----------------------+-------------
|
||||
testuser6 | $2a$10$
|
||||
u_alice_6fed3ed07992 | $2a$10$
|
||||
testuser8 | $2a$10$
|
||||
u_alice_25dca387d520 | $2a$10$
|
||||
u_bob_a13c39c7d441 | $2a$10$
|
||||
(5 rows)
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
python3 scripts/check_contract.py
|
||||
PASS: offline skeleton structure, local refs and Python syntax; application NOT tested.
|
||||
@@ -0,0 +1,8 @@
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.FlywayExecutor - Database: jdbc:postgresql://db:5432/messenger (PostgreSQL 16.14)
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.internal.command.DbValidate - Successfully validated 1 migration (execution time 00:00.022s)
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.internal.command.DbMigrate - Current version of schema "public": 1
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.internal.command.DbMigrate - Schema "public" is up to date. No migration necessary.
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.FlywayExecutor - Database: jdbc:postgresql://db:5432/messenger (PostgreSQL 16.14)
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.internal.command.DbValidate - Successfully validated 1 migration (execution time 00:00.027s)
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.internal.command.DbMigrate - Current version of schema "public": 1
|
||||
mtusi-lab2-api | [main] INFO org.flywaydb.core.internal.command.DbMigrate - Schema "public" is up to date. No migration necessary.
|
||||
@@ -0,0 +1,3 @@
|
||||
python3 tests/resilience.py --mode persistence --action-script "scripts/restart.sh" --base-url "http://localhost:8080"
|
||||
Executing explicit persistence hook; hook output suppressed to avoid leaking secrets.
|
||||
PASS: persistence preserved confirmed data and existing session. Hook scope needs operator evidence.
|
||||
@@ -0,0 +1,14 @@
|
||||
=== POST /chats with unknown member_id ===
|
||||
HTTP/1.1 400 Bad Request
|
||||
Date: Thu, 12 Nov 2026 14:37:22 GMT
|
||||
Content-Type: application/json
|
||||
X-Request-Id: 47ee4821-3dfc-41ec-a9d2-2cf2fc9d6610
|
||||
Content-Length: 116
|
||||
|
||||
{"error":{"code":"invalid_request","message":"invalid_request","request_id":"47ee4821-3dfc-41ec-a9d2-2cf2fc9d6610"}}
|
||||
=== count(chats where title='rollback_probe') ===
|
||||
count
|
||||
-------
|
||||
0
|
||||
(1 row)
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
python3 tests/smoke.py --base-url "http://localhost:8080"
|
||||
PASS: lab2 public API scenario; infrastructure and grading evidence remain separate.
|
||||
Reference in New Issue
Block a user