feat(docs): report.md update and refactored tests

This commit is contained in:
ribardej
2025-11-12 14:42:04 +01:00
parent aade78bf3f
commit e73233c90a
3 changed files with 14 additions and 18 deletions

View File

@@ -1,7 +1,5 @@
import types
import asyncio
import pytest
from fastapi import status
from app.services import user_service
@@ -22,6 +20,15 @@ def test_get_jwt_strategy_lifetime():
# Basic smoke check: strategy has a lifetime set to 604800
assert getattr(strategy, "lifetime_seconds", None) in (604800,)
def test_root_ok(client):
resp = client.get("/")
assert resp.status_code == status.HTTP_200_OK
assert resp.json() == {"status": "ok"}
def test_authenticated_route_requires_auth(client):
resp = client.get("/authenticated-route")
assert resp.status_code in (status.HTTP_401_UNAUTHORIZED, status.HTTP_403_FORBIDDEN)
@pytest.mark.asyncio
async def test_on_after_request_verify_enqueues_email(monkeypatch):