(t *testing.T)
| 400 | } |
| 401 | |
| 402 | func TestHandleDashboardStats_Unauthenticated(t *testing.T) { |
| 403 | ua, _, _ := setupUserAuth(t) |
| 404 | |
| 405 | req := httptest.NewRequest("GET", "/api/dashboard/stats", nil) |
| 406 | w := httptest.NewRecorder() |
| 407 | ua.HandleDashboardStats(w, req) |
| 408 | |
| 409 | if w.Code != http.StatusUnauthorized { |
| 410 | t.Errorf("status = %d, want 401", w.Code) |
| 411 | } |
| 412 | } |
| 413 | |
| 414 | // TestHandleDashboardStats_WindowQueryParam: the same endpoint powers |
| 415 | // both the dashboard at-a-glance strip (default 7-day window) and the |
nothing calls this directly
no test coverage detected