chore: bump eslint 9.39.4 -> 9.39.5
CI / Env docs check (push) Successful in 1m46s
CI / Docker compose check (push) Successful in 51s
CI / Nginx config check (push) Successful in 55s
CI / Frontend deps check (push) Successful in 1m52s
CI / Frontend major deps (push) Failing after 1m6s
CI / Go build (push) Successful in 2m14s
CI / Frontend build (push) Successful in 1m29s
CI / Secrets scan (push) Successful in 2m26s
CI / Knip (push) Successful in 1m4s
CI / Frontend a11y check (push) Successful in 2m18s
CI / Go vet (prod) (push) Successful in 1m51s
CI / Go vet (dev) (push) Successful in 2m11s
CI / go mod tidy (push) Successful in 40s
CI / Staticcheck (prod) (push) Successful in 2m43s
CI / Frontend QC (audit) (push) Successful in 58s
CI / Go vulnerabilities (push) Successful in 1m27s
CI / Staticcheck (dev) (push) Successful in 3m20s
CI / golangci-lint (push) Successful in 3m30s
CI / Frontend QC (typecheck) (push) Successful in 1m26s
CI / Frontend QC (lint) (push) Successful in 1m54s
CI / Security scan (dev) (push) Successful in 4m38s
CI / Security scan (prod) (push) Successful in 4m2s
CI / Svelte strict check (push) Successful in 57s
CI / Tests (prod) (push) Failing after 3m55s
CI / Tests (dev) (push) Failing after 4m9s
CI / Race (prod) (push) Failing after 7m35s
CI / Race (dev) (push) Failing after 7m44s

This commit is contained in:
2026-07-11 00:31:40 +01:00
parent de37b07233
commit ae2acc45c3
3 changed files with 20 additions and 28 deletions
+9 -4
View File
@@ -693,7 +693,7 @@ func TestGetCurrentNext_WithMultipleDataPoints(t *testing.T) {
INSERT INTO bookings (user_id, start_time, status)
VALUES ($1, $2, 'completed')
RETURNING id
`, user1ID, now.Add(-2*time.Hour)).Scan(&booking1ID)
`, user1ID, now.Add(-30*time.Minute)).Scan(&booking1ID)
if err != nil {
t.Fatalf("failed to create booking 1: %v", err)
}
@@ -723,16 +723,21 @@ func TestGetCurrentNext_WithMultipleDataPoints(t *testing.T) {
var booking2ID string
err = tx.QueryRow(ctx, `
INSERT INTO bookings (user_id, start_time, status)
VALUES ($1, $2, 'in_progress')
VALUES ($1, $2, 'completed')
RETURNING id
`, user2ID, now.Add(-3*time.Hour)).Scan(&booking2ID)
`, user2ID, now.Add(-15*time.Minute)).Scan(&booking2ID)
if err != nil {
t.Fatalf("failed to create booking 2: %v", err)
}
addBookingService(t, ctx, tx, booking2ID, svcID)
// Commit the transaction so the handler (which manages its own db.Conn tx) can see the data.
if err := tx.(interface{ Commit(context.Context) error }).Commit(context.Background()); err != nil {
t.Fatalf("failed to commit test data: %v", err)
}
req := httptest.NewRequest(http.MethodGet, "/api/admin/today/current-next", nil)
req = req.WithContext(ctx)
req = req.WithContext(context.Background())
rr := httptest.NewRecorder()
GetCurrentAndNextHandler(rr, req)