发布候选:整合桌面端界面与发布稳定化里程碑
Client Quality Gates / Shared client and Web (push) Has been cancelled
Client Quality Gates / macOS Desktop (push) Has been cancelled
Storage Persistence Guard / storage-persistence-audit (push) Has been cancelled
Client Quality Gates / Shared client and Web (pull_request) Has been cancelled
Client Quality Gates / macOS Desktop (pull_request) Has been cancelled
Storage Persistence Guard / storage-persistence-audit (pull_request) Has been cancelled

This commit is contained in:
Cheng Zhou
2026-07-01 10:53:24 +08:00
parent b283cf1e5c
commit b491b6a146
132 changed files with 17337 additions and 2375 deletions
+16
View File
@@ -70,6 +70,22 @@ async def add_email_settings(SessionLocal, domain: str) -> None:
await session.commit()
@pytest.mark.asyncio
async def test_email_domains_come_only_from_email_service_settings(client_and_db):
client, SessionLocal = client_and_db
empty_response = await client.get("/api/v1/auth/email-domains")
assert empty_response.status_code == 200
assert empty_response.json() == {"items": []}
assert empty_response.headers["cache-control"] == "no-store"
await add_email_settings(SessionLocal, "example.com")
configured_response = await client.get("/api/v1/auth/email-domains")
assert configured_response.status_code == 200
assert configured_response.json() == {"items": ["example.com"]}
assert configured_response.headers["cache-control"] == "no-store"
async def encrypted_auth_payload(client: AsyncClient, email: str, password: str) -> dict:
key_resp = await client.get("/api/v1/auth/login-key")
assert key_resp.status_code == 200