From 702b48ce364fc42f281e17b3d4844ae7cda91649 Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Fri, 11 Sep 2026 14:34:28 -0400 Subject: [PATCH] fix(lidarrquarantine): pass dataDir at the four stub-client test constructors d7a8e5f3 added a dataDir parameter to NewService and updated the 13 call sites spelled NewService(pool, lidarrconfig.New(pool), nil). Four more build their client from a Lidarr stub, NewService(pool, cfg, clientFn), and were missed, so the package's tests did not compile and run 6495 failed both go vet and the integration build. Co-Authored-By: Claude Opus 5 (1M context) Claude-Session: https://claude.ai/code/session_01SQ31KQpYbStyK5y58UmPLH --- internal/lidarrquarantine/service_test.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/internal/lidarrquarantine/service_test.go b/internal/lidarrquarantine/service_test.go index 9f14ae37..8129b01a 100644 --- a/internal/lidarrquarantine/service_test.go +++ b/internal/lidarrquarantine/service_test.go @@ -366,7 +366,7 @@ func TestDeleteViaLidarr_FullCascade(t *testing.T) { t.Fatalf("save config: %v", err) } clientFn := func() *lidarr.Client { return lidarr.NewClient(stub.URL, "k") } - svc := NewService(pool, cfg, clientFn) + svc := NewService(pool, cfg, clientFn, "") q := dbq.New(pool) artist, _ := q.UpsertArtist(context.Background(), dbq.UpsertArtistParams{Name: "A", SortName: "A"}) @@ -456,7 +456,7 @@ func TestDeleteViaLidarr_AlbumMBIDMissing(t *testing.T) { cfg := lidarrconfig.New(pool) _ = cfg.Save(context.Background(), lidarrconfig.Config{Enabled: true, BaseURL: stub.URL, APIKey: "k"}) clientFn := func() *lidarr.Client { return lidarr.NewClient(stub.URL, "k") } - svc := NewService(pool, cfg, clientFn) + svc := NewService(pool, cfg, clientFn, "") _, _ = svc.Flag(context.Background(), user.ID, track.ID, "bad_rip", "") _, _, err := svc.DeleteViaLidarr(context.Background(), track.ID, user.ID) @@ -481,7 +481,7 @@ func TestDeleteViaLidarr_LidarrAlbumNotFound(t *testing.T) { cfg := lidarrconfig.New(pool) _ = cfg.Save(context.Background(), lidarrconfig.Config{Enabled: true, BaseURL: stub.URL, APIKey: "k"}) clientFn := func() *lidarr.Client { return lidarr.NewClient(stub.URL, "k") } - svc := NewService(pool, cfg, clientFn) + svc := NewService(pool, cfg, clientFn, "") track, _, _ := seedTrack(t, pool, "T", "x") _, _ = svc.Flag(context.Background(), user.ID, track.ID, "bad_rip", "") @@ -521,7 +521,7 @@ func TestDeleteViaLidarr_TrackNotFound(t *testing.T) { t.Fatalf("save config: %v", err) } clientFn := func() *lidarr.Client { return lidarr.NewClient(stub.URL, "k") } - svc := NewService(pool, cfg, clientFn) + svc := NewService(pool, cfg, clientFn, "") var bogus pgtype.UUID bogus.Bytes = [16]byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16}