"""最小冒烟:服务能起、/health 通。"""
from __future__ import annotations


def test_health_ok(client) -> None:
    resp = client.get("/health")
    assert resp.status_code == 200
    assert resp.json() == {"status": "ok"}


def test_openapi_loads(client) -> None:
    resp = client.get("/openapi.json")
    assert resp.status_code == 200
    paths = resp.json()["paths"]
    # auth endpoints 都注册了
    assert "/api/v1/auth/jverify-login" in paths
    assert "/api/v1/auth/sms/send" in paths
    assert "/api/v1/auth/sms/login" in paths
    assert "/api/v1/auth/refresh" in paths
    assert "/api/v1/auth/me" in paths
