feat: Update documentation and API for face identification and people management

This commit enhances the README with detailed instructions on the automatic database initialization and schema compatibility between the web and desktop versions. It also introduces new API endpoints for managing unidentified faces and people, including listing, creating, and identifying faces. The schemas for these operations have been updated to reflect the new data structures. Additionally, tests have been added to ensure the functionality of the new API features, improving overall coverage and reliability.
This commit is contained in:
tanyar09
2025-11-03 12:49:48 -05:00
parent 5174fe0d54
commit 817e95337f
13 changed files with 1281 additions and 91 deletions
+24
View File
@@ -0,0 +1,24 @@
from __future__ import annotations
from fastapi.testclient import TestClient
from src.web.app import app
client = TestClient(app)
def test_people_list_empty():
res = client.get('/api/v1/people')
assert res.status_code == 200
data = res.json()
assert 'items' in data and isinstance(data['items'], list)
def test_unidentified_faces_empty():
res = client.get('/api/v1/faces/unidentified')
assert res.status_code == 200
data = res.json()
assert data['total'] >= 0